mirror of
https://github.com/RPCSX/llvm.git
synced 2025-01-08 21:10:31 +00:00
Do not dereference end iterators. It hurts when you do that.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14474 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
8b486a114e
commit
59850a8f8f
@ -356,8 +356,7 @@ void LiveIntervals::handlePhysicalRegisterDef(MachineBasicBlock* mbb,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// a variable can only be killed by subsequent instructions
|
// a variable can only be killed by subsequent instructions
|
||||||
do {
|
for (++mi; mi != e; ++mi) {
|
||||||
++mi;
|
|
||||||
baseIndex += InstrSlots::NUM;
|
baseIndex += InstrSlots::NUM;
|
||||||
for (KillIter ki = lv_->killed_begin(mi), ke = lv_->killed_end(mi);
|
for (KillIter ki = lv_->killed_begin(mi), ke = lv_->killed_end(mi);
|
||||||
ki != ke; ++ki) {
|
ki != ke; ++ki) {
|
||||||
@ -367,7 +366,7 @@ void LiveIntervals::handlePhysicalRegisterDef(MachineBasicBlock* mbb,
|
|||||||
goto exit;
|
goto exit;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} while (mi != e);
|
}
|
||||||
|
|
||||||
exit:
|
exit:
|
||||||
assert(start < end && "did not find end of interval?");
|
assert(start < end && "did not find end of interval?");
|
||||||
|
Loading…
Reference in New Issue
Block a user