[llvm] [VPlan] Materialize constant vector trip counts before final opts. (PR #142309)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 3 12:47:13 PDT 2025
================
@@ -10261,6 +10262,11 @@ bool LoopVectorizePass::processLoop(Loop *L) {
L, PSE, LI, DT, TLI, TTI, AC, ORE, ElementCount::getFixed(1),
ElementCount::getFixed(1), IC, &CM, BFI, PSI, Checks, BestPlan);
+ // TODO: Move to general VPlan pipeline once epilogue loops are also
+ // supported.
+ VPlanTransforms::runPass(VPlanTransforms::materializeVectorTripCount,
+ BestPlan, VF.Width, IC, PSE);
+
----------------
ayalz wrote:
This disables materializeVectorTripCount() from running on both main and epilog loops, when both are vectorized, as opposed to running it in LVP.executePlan() under `if (!VectorizingEpilogue)` - which would disable it only when vectorizing the epilog loop?
https://github.com/llvm/llvm-project/pull/142309
More information about the llvm-commits
mailing list