Skip to content

Commit e8d64a4

Browse files
committed
Use ToRemove
1 parent 4f3acf0 commit e8d64a4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2626,7 +2626,6 @@ expandVPWidenIntOrFpInduction(VPWidenIntOrFpInductionRecipe *WidenIVR,
26262626
WidePHI->addOperand(Next);
26272627

26282628
WidenIVR->replaceAllUsesWith(WidePHI);
2629-
WidenIVR->eraseFromParent();
26302629
}
26312630

26322631
void VPlanTransforms::dissolveLoopRegions(VPlan &Plan) {
@@ -2738,6 +2737,7 @@ void VPlanTransforms::convertToConcreteRecipes(VPlan &Plan,
27382737

27392738
if (auto *WidenIVR = dyn_cast<VPWidenIntOrFpInductionRecipe>(&R)) {
27402739
expandVPWidenIntOrFpInduction(WidenIVR, TypeInfo);
2740+
ToRemove.push_back(WidenIVR);
27412741
continue;
27422742
}
27432743

0 commit comments

Comments
 (0)