From ad956ed568ce8f4d014103cdbf18e3023ca3fc70 Mon Sep 17 00:00:00 2001 From: Valery N Dmitriev Date: Thu, 29 Dec 2022 11:30:10 -0800 Subject: [PATCH] [SLP] Fix debug print for cost in tryToVectorizeList - NFC. Actual VF was confused with local variable named "VF". --- llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp index 7c695b6..744cefb 100644 --- a/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp +++ b/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp @@ -11380,7 +11380,8 @@ bool SLPVectorizerPass::tryToVectorizeList(ArrayRef VL, BoUpSLP &R, CandidateFound = true; MinCost = std::min(MinCost, Cost); - LLVM_DEBUG(dbgs() << "SLP: Found cost = " << Cost << " for VF=" << VF << "\n"); + LLVM_DEBUG(dbgs() << "SLP: Found cost = " << Cost + << " for VF=" << OpsWidth << "\n"); if (Cost < -SLPCostThreshold) { LLVM_DEBUG(dbgs() << "SLP: Vectorizing list at cost:" << Cost << ".\n"); R.getORE()->emit(OptimizationRemark(SV_NAME, "VectorizedList", -- 2.7.4