================
@@ -8430,6 +8479,46 @@ VPlanPtr
LoopVectorizationPlanner::tryToBuildVPlanWithVPRecipes(
// bring the VPlan to its final state.
//
---------------------------------------------------------------------------
+ // Adjust the recipes for any monotonic phis.
+ for (VPRecipeBase &R : HeaderVPBB->phis()) {
+ auto *MonotonicPhi = dyn_cast<VPMonotonicPHIRecipe>(&R);
----------------
lukel97 wrote:
If you use a regular VPInstruction::PHI instead of VPMonotonicPHIRecipe and set
the underlying value to the monotonic phi, could you avoid the need for an
extra recipe?
Would you be able to detect the monotonic phis by just calling
`Legal->getMonotonicPHIs().find(Phi->getUnderlyingValue())`?
https://github.com/llvm/llvm-project/pull/140723
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits