From 9674b869e5be034ef27e6d55568ee7d0f8525206 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Tue, 10 Sep 2002 23:31:12 +0000 Subject: [PATCH] Fix bug in previous checkin llvm-svn: 3672 --- llvm/lib/Transforms/IPO/RaiseAllocations.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/llvm/lib/Transforms/IPO/RaiseAllocations.cpp b/llvm/lib/Transforms/IPO/RaiseAllocations.cpp index cc4573586dcf..241e1f55eeda 100644 --- a/llvm/lib/Transforms/IPO/RaiseAllocations.cpp +++ b/llvm/lib/Transforms/IPO/RaiseAllocations.cpp @@ -123,6 +123,7 @@ bool RaiseAllocations::runOnBasicBlock(BasicBlock &BB) { std::string Name(CI->getName()); CI->setName(""); BI = new MallocInst(PtrSByte, Source, Name, BI); + CI->replaceAllUsesWith(BI); BIL.erase(I); Changed = true; ++NumRaised; -- GitLab