[llvm] 04f7cd7 - [SLP][NFC]Make findBestRootPair() member function constant.

Alexey Bataev via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 20 08:33:58 PDT 2024


Author: Alexey Bataev
Date: 2024-03-20T08:33:47-07:00
New Revision: 04f7cd7f4545f3368ccda625cadbe3265c3566c9

URL: https://github.com/llvm/llvm-project/commit/04f7cd7f4545f3368ccda625cadbe3265c3566c9
DIFF: https://github.com/llvm/llvm-project/commit/04f7cd7f4545f3368ccda625cadbe3265c3566c9.diff

LOG: [SLP][NFC]Make findBestRootPair() member function constant.

Added: 
    

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

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
index 5d59f35f30810e..a52064e5417b27 100644
--- a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+++ b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
@@ -2239,7 +2239,7 @@ class BoUpSLP {
   /// of the cost, considered to be good enough score.
   std::optional<int>
   findBestRootPair(ArrayRef<std::pair<Value *, Value *>> Candidates,
-                   int Limit = LookAheadHeuristics::ScoreFail) {
+                   int Limit = LookAheadHeuristics::ScoreFail) const {
     LookAheadHeuristics LookAhead(*TLI, *DL, *SE, *this, /*NumLanes=*/2,
                                   RootLookAheadMaxDepth);
     int BestScore = Limit;


        


More information about the llvm-commits mailing list