[llvm] [VPlan] Introduce explicit ExtractFromEnd recipes for live-outs. (PR #100658)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 29 10:42:04 PDT 2024
================
@@ -8660,6 +8757,14 @@ LoopVectorizationPlanner::tryToBuildVPlanWithVPRecipes(VFRange &Range) {
// After here, VPBB should not be used.
VPBB = nullptr;
+ assert(isa<VPRegionBlock>(Plan->getVectorLoopRegion()) &&
+ !Plan->getVectorLoopRegion()->getEntryBasicBlock()->empty() &&
+ "entry block must be set to a VPRegionBlock having a non-empty entry "
+ "VPBasicBlock");
+ RecipeBuilder.fixHeaderPhis();
+
+ addLiveOutsForFirstOrderRecurrences(*Plan);
----------------
ayalz wrote:
Now that addLiveOutsForFirstOrderRecurrences() moves to be ahead of addUsersInExitBlock() - could the former add *all* live-outs of FORs, both those in scalar header and those in exit block (when scalar epilog isn't required)?
Independent, while we're here: name should be `addLiveOutsForFixedOrderRecurrences()` - as it deals with FOR's of distance >= 1, right? May be a bit confusing, along with "optimizing" the extract of v2's penultimate value instead of v3's last value.
https://github.com/llvm/llvm-project/pull/100658
More information about the llvm-commits
mailing list