[Mlir-commits] [mlir] [mlir][vector] Fold vector extract from insert when trailing unit dims (PR #192109)
Mehdi Amini
llvmlistbot at llvm.org
Wed Apr 15 09:33:04 PDT 2026
joker-eph wrote:
> Thanks! I spent some time thinking about this. I am leaning towards agreeing with @Groverkss that this is not implicit broadcast.
OK, so instead of saying what it isn't, can you expand on what it is? A shape_cast?
Also, I'm interested in reconciling this with my question about why are you inserting a broadcast when folding away a "no-op" extract/insert? How do you reconcile the need for this "broadcast" in the semantics of the original IR?
> It is transformed into a vector.shape_cast but only after this pattern is applied first.
Can we emit a shape_cast instead of a broadcast in your pattern when the type is a vector already?
https://github.com/llvm/llvm-project/pull/192109
More information about the Mlir-commits
mailing list