mirror of
https://github.com/RPCS3/llvm.git
synced 2025-02-08 11:37:03 +00:00
Simplify moveEnteringDownFrom rules.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150914 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
dd637ae0c3
commit
4a0b2d658a
@ -1205,17 +1205,9 @@ private:
|
||||
void moveEnteringDownFrom(SlotIndex OldIdx, IntRangePair& P) {
|
||||
LiveInterval* LI = P.first;
|
||||
LiveRange* LR = P.second;
|
||||
bool LiveThrough = LR->end > OldIdx.getRegSlot();
|
||||
if (LiveThrough) {
|
||||
MachineBasicBlock* MBB = LIS.getInstructionFromIndex(NewIdx)->getParent();
|
||||
bool LiveOut = LR->end >= LIS.getSlotIndexes()->getMBBEndIdx(MBB);
|
||||
if (!LiveOut) {
|
||||
moveKillFlags(LI->reg, LR->end, NewIdx);
|
||||
LR->end = NewIdx.getRegSlot(LR->end.isEarlyClobber());
|
||||
}
|
||||
} else {
|
||||
// Not live through. Easy - just update the range endpoint.
|
||||
LR->end = NewIdx.getRegSlot(LR->end.isEarlyClobber());
|
||||
if (NewIdx > LR->end) {
|
||||
moveKillFlags(LI->reg, LR->end, NewIdx);
|
||||
LR->end = NewIdx.getRegSlot();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user