[llvm] 0b24436 - [LV] Clarify comment for selectVectorizationFactor (NFC).

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Sun Apr 30 13:12:37 PDT 2023


Author: Florian Hahn
Date: 2023-04-30T21:12:15+01:00
New Revision: 0b24436591e1bbea5943d7ef816544f2d90d26d2

URL: https://github.com/llvm/llvm-project/commit/0b24436591e1bbea5943d7ef816544f2d90d26d2
DIFF: https://github.com/llvm/llvm-project/commit/0b24436591e1bbea5943d7ef816544f2d90d26d2.diff

LOG: [LV] Clarify comment for selectVectorizationFactor (NFC).

The comment is stale, as UserVF is handled before selectVectorizationFactor
is called. Clarify the comment by remove the mention of UserVF.

Suggested as independent improvement in D143938.

Added: 
    

Modified: 
    llvm/lib/Transforms/Vectorize/LoopVectorize.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
index 6affd5a95e36..ea70036b3477 100644
--- a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
+++ b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
@@ -1193,9 +1193,7 @@ class LoopVectorizationCostModel {
   bool runtimeChecksRequired();
 
   /// \return The most profitable vectorization factor and the cost of that VF.
-  /// This method checks every VF in \p CandidateVFs. If UserVF is not ZERO
-  /// then this vectorization factor will be selected if vectorization is
-  /// possible.
+  /// This method checks every VF in \p CandidateVFs.
   VectorizationFactor
   selectVectorizationFactor(const ElementCountSet &CandidateVFs);
 


        


More information about the llvm-commits mailing list