mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-13 04:38:24 +00:00
Revert "[C++11] Add predecessors(BasicBlock *) / successors(BasicBlock *) iterator ranges."
This reverts commit r213474 (and r213475), which causes a miscompile on a stage2 LTO build. I'll reply on the list in a moment. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@213562 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -549,11 +549,14 @@ void llvm::SplitLandingPadPredecessors(BasicBlock *OrigBB,
|
||||
|
||||
// Move the remaining edges from OrigBB to point to NewBB2.
|
||||
SmallVector<BasicBlock*, 8> NewBB2Preds;
|
||||
for (BasicBlock *Pred : predecessors(OrigBB)) {
|
||||
for (pred_iterator i = pred_begin(OrigBB), e = pred_end(OrigBB);
|
||||
i != e; ) {
|
||||
BasicBlock *Pred = *i++;
|
||||
if (Pred == NewBB1) continue;
|
||||
assert(!isa<IndirectBrInst>(Pred->getTerminator()) &&
|
||||
"Cannot split an edge from an IndirectBrInst");
|
||||
NewBB2Preds.push_back(Pred);
|
||||
e = pred_end(OrigBB);
|
||||
}
|
||||
|
||||
BasicBlock *NewBB2 = nullptr;
|
||||
|
Reference in New Issue
Block a user