diff options
Diffstat (limited to 'llvm/lib/Transforms/Vectorize/LoopVectorizationPlanner.h')
| -rw-r--r-- | llvm/lib/Transforms/Vectorize/LoopVectorizationPlanner.h | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/llvm/lib/Transforms/Vectorize/LoopVectorizationPlanner.h b/llvm/lib/Transforms/Vectorize/LoopVectorizationPlanner.h index c03c278fcebe..93f6d1d82e24 100644 --- a/llvm/lib/Transforms/Vectorize/LoopVectorizationPlanner.h +++ b/llvm/lib/Transforms/Vectorize/LoopVectorizationPlanner.h @@ -262,16 +262,6 @@ struct VectorizationFactor { } }; -/// ElementCountComparator creates a total ordering for ElementCount -/// for the purposes of using it in a set structure. -struct ElementCountComparator { - bool operator()(const ElementCount &LHS, const ElementCount &RHS) const { - return std::make_tuple(LHS.isScalable(), LHS.getKnownMinValue()) < - std::make_tuple(RHS.isScalable(), RHS.getKnownMinValue()); - } -}; -using ElementCountSet = SmallSet<ElementCount, 16, ElementCountComparator>; - /// A class that represents two vectorization factors (initialized with 0 by /// default). One for fixed-width vectorization and one for scalable /// vectorization. This can be used by the vectorizer to choose from a range of @@ -442,10 +432,9 @@ private: VPRecipeBuilder &RecipeBuilder, ElementCount MinVF); - /// \return The most profitable vectorization factor and the cost of that VF. - /// This method checks every VF in \p CandidateVFs. - VectorizationFactor - selectVectorizationFactor(const ElementCountSet &CandidateVFs); + /// \return The most profitable vectorization factor for the available VPlans + /// and the cost of that VF. + VectorizationFactor selectVectorizationFactor(); /// Returns true if the per-lane cost of VectorizationFactor A is lower than /// that of B. |
