aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Christopher <echristo@gmail.com>2021-09-10 18:10:16 -0700
committerEric Christopher <echristo@gmail.com>2021-09-10 18:10:53 -0700
commit2d26a72f825c7d8b50da49dda917e85897c8a746 (patch)
tree10b16bcd0b0b2c77cef3a08b50b79672ed6732ec
parentf7062f6dfbbcc3ac13c215a620bbbe3806fa2c77 (diff)
downloadllvm-2d26a72f825c7d8b50da49dda917e85897c8a746.zip
llvm-2d26a72f825c7d8b50da49dda917e85897c8a746.tar.gz
llvm-2d26a72f825c7d8b50da49dda917e85897c8a746.tar.bz2
nullptr initialize variables, spotted on msan bots.
-rw-r--r--llvm/lib/Transforms/Scalar/LoopFlatten.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Scalar/LoopFlatten.cpp b/llvm/lib/Transforms/Scalar/LoopFlatten.cpp
index 83d7899..931bcc2 100644
--- a/llvm/lib/Transforms/Scalar/LoopFlatten.cpp
+++ b/llvm/lib/Transforms/Scalar/LoopFlatten.cpp
@@ -424,8 +424,8 @@ static bool checkIVUsers(FlattenInfo &FI) {
LLVM_DEBUG(dbgs() << "Found use of inner induction variable: "; U->dump());
- Value *MatchedMul;
- Value *MatchedItCount;
+ Value *MatchedMul = nullptr;
+ Value *MatchedItCount = nullptr;
bool IsAdd = match(U, m_c_Add(m_Specific(FI.InnerInductionPHI),
m_Value(MatchedMul))) &&
match(MatchedMul, m_c_Mul(m_Specific(FI.OuterInductionPHI),