[llvm] Patch 1: [LV][NFCI] Parameterize CM instance for the Planner (PR #202818)
Hassnaa Hamdi via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 30 08:20:56 PDT 2026
================
@@ -803,9 +803,6 @@ class LoopVectorizationPlanner {
/// The legality analysis.
LoopVectorizationLegality *Legal;
- /// The profitability analysis.
- LoopVectorizationCostModel &CM;
----------------
hassnaaHamdi wrote:
Sometimes I need both instances at same time, for example at functions: `plan(..)` and `computeBestVF` because some of the logic of those functions should be run for the default CM and some other logic is for the second CM.
For example in `plan(..)`, if the user is specifying VF, we use the `UserVf` for the first CM and we use the `EpilogueUserVF` for the second CM, so we need both instances.
https://github.com/llvm/llvm-project/pull/202818
More information about the llvm-commits
mailing list