[llvm] [LV] Support tail-folded epilogue loops (PR #208764)
David Sherwood via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 7 06:56:43 PDT 2026
================
@@ -5934,6 +6086,22 @@ LoopVectorizationPlanner::computeBestVF() {
return {BestFactor, &BestPlan};
}
+LoopVectorizationPlanner::LoopVectorizationPlanner(
+ Loop *L, LoopInfo *LI, DominatorTree *DT, const TargetLibraryInfo *TLI,
+ const TargetTransformInfo &TTI, LoopVectorizationLegality *Legal,
+ LoopVectorizationCostModel &CM,
+ std::unique_ptr<LoopVectorizationCostModel> EpilogueTfCM,
+ VFSelectionContext &Config, InterleavedAccessInfo &IAI,
+ PredicatedScalarEvolution &PSE, const LoopVectorizeHints &Hints,
+ OptimizationRemarkEmitter *ORE)
+ : OrigLoop(L), LI(LI), DT(DT), TLI(TLI), TTI(TTI), Legal(Legal), CM(CM),
+ EpilogueTfCM(std::move(EpilogueTfCM)), Config(Config), IAI(IAI), PSE(PSE),
+ Hints(Hints), ORE(ORE) {}
+
+LoopVectorizationPlanner::~LoopVectorizationPlanner() = default;
+
+void LoopVectorizationPlanner::clearEpilogueTfCM() { EpilogueTfCM.reset(); }
----------------
david-arm wrote:
I tried moving this myself to LoopVectorizationPlanner.h and I see that it fails to build due to not being able to see the full LoopVectorizationCostModel type.
https://github.com/llvm/llvm-project/pull/208764
More information about the llvm-commits
mailing list