[llvm] 5f0b3d6 - [SLP][NFC]Fix formatting and debug printing, NFC
Alexey Bataev via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 24 09:06:34 PDT 2026
Author: Alexey Bataev
Date: 2026-03-24T09:06:22-07:00
New Revision: 5f0b3d6af425d2cd849a5914d5bb65d45f091cca
URL: https://github.com/llvm/llvm-project/commit/5f0b3d6af425d2cd849a5914d5bb65d45f091cca
DIFF: https://github.com/llvm/llvm-project/commit/5f0b3d6af425d2cd849a5914d5bb65d45f091cca.diff
LOG: [SLP][NFC]Fix formatting and debug printing, NFC
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 b5f9d479ccfb1..25ba77dca7e93 100644
--- a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+++ b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
@@ -17841,7 +17841,7 @@ InstructionCost BoUpSLP::calculateTreeCostAndTrimNonProfitable(
LLVM_DEBUG(dbgs() << "SLP: Adding cost " << P.second << " for bundle "
<< shortBundleName(P.first->Scalars, P.first->Idx)
<< ".\n"
- << "SLP: Current total cost = " << Cost << "\n");
+ << "SLP: Current total cost = " << NewCost << "\n");
}
if (NewCost + LoadsExtractsCost >= Cost) {
DeletedNodes.clear();
@@ -17850,9 +17850,9 @@ InstructionCost BoUpSLP::calculateTreeCostAndTrimNonProfitable(
} else {
// If the remaining tree is just a buildvector - exit, it will cause
// endless attempts to vectorize.
- if (VectorizableTree.size()>= 2 && VectorizableTree.front()->hasState() &&
+ if (VectorizableTree.size() >= 2 && VectorizableTree.front()->hasState() &&
VectorizableTree.front()->getOpcode() == Instruction::InsertElement &&
- TransformedToGatherNodes.contains(VectorizableTree[1].get()))
+ TransformedToGatherNodes.contains(VectorizableTree[1].get()))
return InstructionCost::getInvalid();
if (VectorizableTree.size() >= 3 && VectorizableTree.front()->hasState() &&
VectorizableTree.front()->getOpcode() == Instruction::InsertElement &&
More information about the llvm-commits
mailing list