[llvm] [LV] Support multiplies by constants when forming scaled reductions. (PR #161092)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 2 04:07:35 PDT 2025
================
@@ -7954,6 +7954,13 @@ bool VPRecipeBuilder::getScaledReductions(
auto CollectExtInfo = [this, &Exts, &ExtOpTypes,
&ExtKinds](SmallVectorImpl<Value *> &Ops) -> bool {
for (const auto &[I, OpI] : enumerate(Ops)) {
+ auto *CI = dyn_cast<ConstantInt>(OpI);
+ if (I > 0 && CI &&
----------------
fhahn wrote:
We can't drop the first operand, as it needs to be handled below.
https://github.com/llvm/llvm-project/pull/161092
More information about the llvm-commits
mailing list