[llvm] 778a582 - Fix a -Wunused-variable warning in release build.

Haojian Wu via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 20 14:40:44 PST 2023


Author: Haojian Wu
Date: 2023-01-20T23:40:33+01:00
New Revision: 778a582e8e464e101f3f3cc3f13defe0fa0af265

URL: https://github.com/llvm/llvm-project/commit/778a582e8e464e101f3f3cc3f13defe0fa0af265
DIFF: https://github.com/llvm/llvm-project/commit/778a582e8e464e101f3f3cc3f13defe0fa0af265.diff

LOG: Fix a -Wunused-variable warning in release build.

Added: 
    

Modified: 
    llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp b/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
index 3818ef2a02bf..4c89f947d7fc 100644
--- a/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
+++ b/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
@@ -6835,6 +6835,7 @@ static bool ReduceLoopStrength(Loop *L, IVUsers &IU, ScalarEvolution &SE,
                         << *ToHelpFold << "\n");
 
       Value *StartValue = ToHelpFold->getIncomingValueForBlock(LoopPreheader);
+      (void)StartValue;
       Value *LoopValue = ToHelpFold->getIncomingValueForBlock(LoopLatch);
 
       // SCEVExpander for both use in preheader and latch


        


More information about the llvm-commits mailing list