mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 19:52:54 +01:00
Fix bug: 2004-11-08-FreeUseCrash.ll
llvm-svn: 17642
This commit is contained in:
parent
eabfcfca53
commit
b924e8be62
@ -201,7 +201,9 @@ bool RaiseAllocations::runOnModule(Module &M) {
|
|||||||
new BranchInst(II->getNormalDest(), I);
|
new BranchInst(II->getNormalDest(), I);
|
||||||
|
|
||||||
// Delete the old call site
|
// Delete the old call site
|
||||||
I->getParent()->getInstList().erase(I);
|
if (I->getType() != Type::VoidTy)
|
||||||
|
I->replaceAllUsesWith(UndefValue::get(I->getType()));
|
||||||
|
I->eraseFromParent();
|
||||||
Changed = true;
|
Changed = true;
|
||||||
++NumRaised;
|
++NumRaised;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user