You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Arm backend: Add pass order validation to ArmPassManager (#14148)
Introduce a mechanism to enforce required ordering of passes in
ArmPassManager. Each ArmPass must now declare which passes are required
to run after it, ensuring ordering constraints are always upheld.
This prevents accidental breakage when modifying pass ordering in the
manager.
Ordering constraints are verified by the new method
ArmPass.validate_constraints_mandatory. We considered reusing
torch.fx.passes.infra.pass_manager.PassManager.validate_constraints, but
that utility only checks pairwise ordering and cannot enforce that a
pass is actually run, which did not meet our needs.
This patch only implements the mechanism and tests for it. Defining the
actual pass orderings are done in a later patch.
### Test plan
The change comes with added unit tests in
backends/arm/test/misc/test_pass_required_order.py
Signed-off-by: Adrian Lundell <[email protected]>
Signed-off-by: Martin Lindström <[email protected]>
Co-authored-by: Adrian Lundell <[email protected]>
Co-authored-by: Martin Lindström <[email protected]>
0 commit comments