commit | d8b4fb4aab4d6fedb2b14bed1b846451b17bde7c | [log] [tgz] |
---|---|---|
author | Jay Foad <jay.foad@gmail.com> | Wed Mar 30 11:19:20 2011 +0000 |
committer | Jay Foad <jay.foad@gmail.com> | Wed Mar 30 11:19:20 2011 +0000 |
tree | fb1299f91120b2d0bf513abc2ac6f42393fc627d | |
parent | 8be7d8b43cef4fda9dec3ce05449e3d74c25fb04 [diff] [blame] |
(Almost) always call reserveOperandSpace() on newly created PHINodes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128535 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Transforms/Scalar/LoopStrengthReduce.cpp b/lib/Transforms/Scalar/LoopStrengthReduce.cpp index 1bc6f52..b816dd5 100644 --- a/lib/Transforms/Scalar/LoopStrengthReduce.cpp +++ b/lib/Transforms/Scalar/LoopStrengthReduce.cpp
@@ -1492,6 +1492,7 @@ /* Add new PHINode. */ PHINode *NewPH = PHINode::Create(DestTy, "IV.S.", PH); + NewPH->reserveOperandSpace(2); /* create new increment. '++d' in above example. */ Constant *CFP = ConstantFP::get(DestTy, C->getZExtValue());