[llvm] [LV] Bundle sub reductions into VPExpressionRecipe (PR #147255)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 29 11:17:03 PDT 2025


================
@@ -1468,8 +1468,8 @@ static void analyzeCostOfVecReduction(const IntrinsicInst &II,
                              TTI::CastContextHint::None, CostKind, RedOp);
 
     CostBeforeReduction = ExtCost * 2 + MulCost + Ext2Cost;
-    CostAfterReduction =
-        TTI.getMulAccReductionCost(IsUnsigned, II.getType(), ExtType, CostKind);
+    CostAfterReduction = TTI.getMulAccReductionCost(
+        IsUnsigned, ReductionOpc, II.getType(), ExtType, CostKind);
----------------
fhahn wrote:

it would be nice to have a test for this, but not sure if that's possible.

https://github.com/llvm/llvm-project/pull/147255


More information about the llvm-commits mailing list