mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 10:42:39 +01:00
Fix a memory leak after rL341386.
Reviewers: davidxl Reviewed By: davidxl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D51658 llvm-svn: 341412
This commit is contained in:
parent
1312bc6529
commit
3b619a8745
@ -1753,8 +1753,8 @@ BranchInst *CHR::createMergedBranch(BasicBlock *PreEntryBlock,
|
||||
"NewEntryBlock's only pred must be EntryBlock");
|
||||
assert(VMap.find(NewEntryBlock) != VMap.end() &&
|
||||
"NewEntryBlock must have been copied");
|
||||
OldBR->removeFromParent();
|
||||
OldBR->dropAllReferences();
|
||||
OldBR->eraseFromParent();
|
||||
// The true predicate is a placeholder. It will be replaced later in
|
||||
// fixupBranchesAndSelects().
|
||||
BranchInst *NewBR = BranchInst::Create(NewEntryBlock,
|
||||
|
Loading…
Reference in New Issue
Block a user