Remove use of reverse iterators in repairIntervalsInRange(). While they were

arguably better than forward iterators for this use case, they are confusing and
there are some implementation problems with reverse iterators and MI bundles.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175393 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Cameron Zwarich
2013-02-17 11:09:00 +00:00
parent 7324d4e593
commit 680c98f632
3 changed files with 18 additions and 21 deletions

View File

@@ -851,15 +851,7 @@ MachineBasicBlock::SplitCriticalEdge(MachineBasicBlock *Succ, Pass *P) {
// Update all intervals for registers whose uses may have been modified by
// updateTerminator().
iterator FirstTerminator = getFirstTerminator();
reverse_iterator PreTerminators;
if (FirstTerminator == begin())
PreTerminators = rend();
else if (FirstTerminator == end())
PreTerminators = rbegin();
else
PreTerminators = reverse_iterator(FirstTerminator);
LIS->repairIntervalsInRange(this, rbegin(), PreTerminators, UsedRegs);
LIS->repairIntervalsInRange(this, getFirstTerminator(), end(), UsedRegs);
}
if (MachineDominatorTree *MDT =