[llvm] [LV] Simplify the chain traversal in `getScaledReductions()` (NFCI) (PR #184830)
Gaƫtan Bossu via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 6 01:02:09 PST 2026
================
----------------
gbossu wrote:
Nit: Not your doing, but the comment mentions a "valid partial reduction". It would be helpful to document which valid forms are expected. According to `MatchExtends`, I think we expect:
* either `UpdateR( BinOp(ext(...), ext(...)), Phi )`
* or `UpdateR( ext(...), Phi )`
And on top of that, we add another layer here to match `UpdateR( ext(BinOp(ext(...), ext(...))), Phi )`. But this new ext isn't added to `CastRecipes` for some reason. I think it would help to match the simple `UpdateR( ext(...), Phi )` case first and have an early exit. In another PR if you agree :)
https://github.com/llvm/llvm-project/pull/184830
More information about the llvm-commits
mailing list