mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-25 21:18:19 +00:00
Make succ_iterator a real random access iterator and clean up a couple of users.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@201088 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -168,8 +168,7 @@ static bool isPotentiallyReachableInner(SmallVectorImpl<BasicBlock *> &Worklist,
|
||||
// ignoring any other blocks inside the loop body.
|
||||
Outer->getExitBlocks(Worklist);
|
||||
} else {
|
||||
for (succ_iterator I = succ_begin(BB), E = succ_end(BB); I != E; ++I)
|
||||
Worklist.push_back(*I);
|
||||
Worklist.append(succ_begin(BB), succ_end(BB));
|
||||
}
|
||||
} while (!Worklist.empty());
|
||||
|
||||
@@ -222,8 +221,7 @@ bool llvm::isPotentiallyReachable(const Instruction *A, const Instruction *B,
|
||||
return false;
|
||||
|
||||
// Otherwise, continue doing the normal per-BB CFG walk.
|
||||
for (succ_iterator I = succ_begin(BB), E = succ_end(BB); I != E; ++I)
|
||||
Worklist.push_back(*I);
|
||||
Worklist.append(succ_begin(BB), succ_end(BB));
|
||||
|
||||
if (Worklist.empty()) {
|
||||
// We've proven that there's no path!
|
||||
|
||||
Reference in New Issue
Block a user