Repository navigation
[GlobalOptimization] Expose reusable transpose propagation patterns - #24978
Merged
Merged
Conversation
ziereis
force-pushed
the
users/ziereis/qdq-transpose-pattern-refactor
branch
4 times, most recently
from
September 30, 2026 15:25
5f74093 to
8e2cdbf
Compare
Move the transpose propagation patterns out of PropagateLinalgTranspose into TransposePropagationPatterns so other passes can reuse them. Each pattern is exposed through its own populate function, and the pattern classes stay private to the implementation file. Generic transpose specialization is exposed both as a function, which the pass keeps applying with its original walk, and as a pattern for greedy callers. Patterns no longer depend on Flow. Scope and profitability decisions come from a ControlTransposePropagationFn. The patterns call it once, after the structural match, with the use edge that the transpose moves across. The pass supplies the previous policy: stay outside of dispatches, keep sunk extract_slice ops mappable to Flow, and restrict reshape propagation at graph edges. Named-op generalization and convolution support stay pattern options because they describe what the rewrite can handle safely. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: Thomas Ziereis <[email protected]>
ziereis
force-pushed
the
users/ziereis/qdq-transpose-pattern-refactor
branch
from
September 30, 2026 15:32
8e2cdbf to
6854dae
Compare
ziereis
marked this pull request as ready for review
September 30, 2026 16:07
ziereis
requested review from
AGindinson,
Manewing,
egebeysel and
phemashekar
as code owners
September 30, 2026 16:07
AGindinson
approved these changes
Oct 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I ran into multiple scenarios in the past (and now again for #24906) where i had to reimplement some form of transpose propagation. To improve this, this PR refactors the transpose propagation pass into reusable patterns.
This PR should not cause any functional changes and should be a pure refactor.
Assisted by: Claude