Changes in directory llvm/lib/Transforms/Scalar:
LICM.cpp updated: 1.101 -> 1.102 --- Log message: Insert new instructions in AliasSet. --- Diffs of the changes: (+5 -1) LICM.cpp | 6 +++++- 1 files changed, 5 insertions(+), 1 deletion(-) Index: llvm/lib/Transforms/Scalar/LICM.cpp diff -u llvm/lib/Transforms/Scalar/LICM.cpp:1.101 llvm/lib/Transforms/Scalar/LICM.cpp:1.102 --- llvm/lib/Transforms/Scalar/LICM.cpp:1.101 Wed May 30 10:29:37 2007 +++ llvm/lib/Transforms/Scalar/LICM.cpp Fri Jun 1 17:15:31 2007 @@ -476,9 +476,11 @@ // Firstly, we create a stack object to hold the value... AllocaInst *AI = 0; - if (I.getType() != Type::VoidTy) + if (I.getType() != Type::VoidTy) { AI = new AllocaInst(I.getType(), 0, I.getName(), I.getParent()->getParent()->getEntryBlock().begin()); + CurAST->add(AI); + } // Secondly, insert load instructions for each use of the instruction // outside of the loop. @@ -499,6 +501,7 @@ // Insert a new load instruction right before the terminator in // the predecessor block. PredVal = new LoadInst(AI, "", Pred->getTerminator()); + CurAST->add(cast<LoadInst>(PredVal)); } UPN->setIncomingValue(i, PredVal); @@ -507,6 +510,7 @@ } else { LoadInst *L = new LoadInst(AI, "", U); U->replaceUsesOfWith(&I, L); + CurAST->add(L); } } _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits