mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-13 16:03:58 +00:00
Revert part of r91101 which was causing an infinite loop in the self-hosting
build bots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91113 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
be1ce0a867
commit
a288b2f43a
@ -457,11 +457,16 @@ MachineBasicBlock::BranchesToLandingPad(const MachineBasicBlock *MBB) const {
|
||||
SmallSet<const MachineBasicBlock*, 32> Visited;
|
||||
const MachineBasicBlock *CurMBB = MBB;
|
||||
|
||||
while (!CurMBB->isLandingPad()) {
|
||||
if (CurMBB->succ_size() != 1)
|
||||
while (!Visited.count(CurMBB) && !CurMBB->isLandingPad()) {
|
||||
if (CurMBB->size() != 1 || CurMBB->succ_empty() || CurMBB->succ_size() != 1)
|
||||
break;
|
||||
|
||||
if (!Visited.insert(CurMBB)) break;
|
||||
const TargetInstrInfo *TII =
|
||||
CurMBB->getParent()->getTarget().getInstrInfo();
|
||||
if (!TII->isUnpredicatedTerminator(CurMBB->begin()))
|
||||
break;
|
||||
|
||||
Visited.insert(CurMBB);
|
||||
CurMBB = *CurMBB->succ_begin();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user