Programs that actually free memory were broken
authorChris Lattner <sabre@nondot.org>
Thu, 18 Apr 2002 22:11:30 +0000 (22:11 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 18 Apr 2002 22:11:30 +0000 (22:11 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2307 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/IPO/OldPoolAllocate.cpp

index 1e63381c893c57c6df112df78d80743fabcb1d87..0620d1d02d9cda30c153ccc89639fc23989b81c7 100644 (file)
@@ -570,7 +570,7 @@ public:
     Args.push_back(getScalarRef(I->getOperand(0)).Pool.Handle);
     Instruction *NewCall = new CallInst(PoolAllocator.PoolFree, Args);
     ReplaceInstWith(I, NewCall);
-    ReferencesToUpdate.push_back(RefToUpdate(NewCall, 0, I->getOperand(0)));
+    ReferencesToUpdate.push_back(RefToUpdate(NewCall, 1, I->getOperand(0)));
   }
 
   // visitCallInst - Create a new call instruction with the extra arguments for