Skip to content

Commit 909de8b

Browse files
Add a couple of missing CostKind
1 parent c4cf6aa commit 909de8b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1122,7 +1122,7 @@ InstructionCost VPHistogramRecipe::computeCost(ElementCount VF,
11221122
// Assume that a non-constant update value (or a constant != 1) requires
11231123
// a multiply, and add that into the cost.
11241124
InstructionCost MulCost =
1125-
Ctx.TTI.getArithmeticInstrCost(Instruction::Mul, VTy);
1125+
Ctx.TTI.getArithmeticInstrCost(Instruction::Mul, VTy, Ctx.CostKind);
11261126
if (IncAmt->isLiveIn()) {
11271127
ConstantInt *CI = dyn_cast<ConstantInt>(IncAmt->getLiveInIRValue());
11281128

@@ -1139,7 +1139,7 @@ InstructionCost VPHistogramRecipe::computeCost(ElementCount VF,
11391139

11401140
// Add the costs together with the add/sub operation.
11411141
return Ctx.TTI.getIntrinsicInstrCost(ICA, Ctx.CostKind) + MulCost +
1142-
Ctx.TTI.getArithmeticInstrCost(Opcode, VTy);
1142+
Ctx.TTI.getArithmeticInstrCost(Opcode, VTy, Ctx.CostKind);
11431143
}
11441144

11451145
#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)

0 commit comments

Comments
 (0)