[llvm] Add LoopVectorizer support for `llvm.vector.partial.reduce.fadd` (PR #163975)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 16 03:13:38 PST 2025


================
@@ -2703,11 +2707,12 @@ InstructionCost VPReductionRecipe::computeCost(ElementCount VF,
       CondCost = Ctx.TTI.getCmpSelInstrCost(Instruction::Select, VectorTy,
                                             CondTy, Pred, Ctx.CostKind);
     }
+    auto *PhiType = Ctx.Types.inferScalarType(getChainOp());
+    auto *InputType = Ctx.Types.inferScalarType(getVecOp());
----------------
fhahn wrote:

How is this change related to the current patch? Shouldn't all operands have the same types, as we are passing PR_None?

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


More information about the llvm-commits mailing list