mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-03 15:36:21 +00:00
Add an assertion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29199 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2698a08c23
commit
10d9d9f27c
@ -272,6 +272,8 @@ bool LoopUnroll::visitLoop(Loop *L) {
|
||||
// Remove LCSSA Phis from the exit block
|
||||
for (BasicBlock::iterator ExitInstr = LoopExit->begin();
|
||||
PHINode* PN = dyn_cast<PHINode>(ExitInstr); ++ExitInstr) {
|
||||
assert(PN->getNumIncomingValues() == 1
|
||||
&& "Block should only have one pred, so Phi's must be LCSSA");
|
||||
PN->replaceAllUsesWith(PN->getOperand(0));
|
||||
PN->eraseFromParent();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user