Skip to content

Abstract Backend testing logic #10100

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
skywall opened this issue Apr 11, 2025 · 2 comments
Open

Abstract Backend testing logic #10100

skywall opened this issue Apr 11, 2025 · 2 comments
Labels
module: arm Issues related to arm backend module: backend Issues related to backend APIs or requests for new backends module: xnnpack Issues related to xnnpack delegation and the code under backends/xnnpack/ triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Comments

@skywall
Copy link
Collaborator

skywall commented Apr 11, 2025

🚀 The feature, motivation and pitch

Backend testing lacks reusable base Tester class. To improve extensibility, let's refactor XNNPACKTester into a more abstract BackendTester and move it to backends/test. XNNPACKTester, ArmTester, and a new NeutronTester should then derive from BackendTester.

Alternatives

No response

Additional context

No response

RFC (Optional)

No response

cc @digantdesai @mcr229 @cbilgin @cccclai

@lucylq lucylq added triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module module: xnnpack Issues related to xnnpack delegation and the code under backends/xnnpack/ module: backend Issues related to backend APIs or requests for new backends module: arm Issues related to arm backend labels Apr 11, 2025
@mcr229
Copy link
Contributor

mcr229 commented Apr 11, 2025

yea we've been meaning to do something like this. The idea would be that the Tester Base class stays the same, but each backend will have their own configurable stages (Export, Quantize, ToBackend, etc..) And backends can configure those stages to do what their expected flow is (for example XNNPACK's ToBackend stage would choose XNNPACKPartitioner to lower the model). I believe @GregoryComer has some other ideas for auto generating tests as well to give all backends native strong coverage.

@GregoryComer
Copy link
Member

Yeah, having common delegate test infra would be helpful across the board. Ideally we can use it to make common backend tests "plug and play" with each delegate by dropping in the relevant tester implementation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module: arm Issues related to arm backend module: backend Issues related to backend APIs or requests for new backends module: xnnpack Issues related to xnnpack delegation and the code under backends/xnnpack/ triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module
Projects
None yet
Development

No branches or pull requests

4 participants