mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-13 04:38:24 +00:00
Represent RegUnit liveness with LiveRange instance
Previously LiveInterval has been used, but having a spill weight and register number is unnecessary for a register unit. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192397 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -1106,10 +1106,10 @@ foldMemoryOperand(ArrayRef<std::pair<MachineInstr*, unsigned> > Ops,
|
||||
// FoldMI does not define this physreg. Remove the LI segment.
|
||||
assert(MO->isDead() && "Cannot fold physreg def");
|
||||
for (MCRegUnitIterator Units(Reg, &TRI); Units.isValid(); ++Units) {
|
||||
if (LiveInterval *LI = LIS.getCachedRegUnit(*Units)) {
|
||||
if (LiveRange *LR = LIS.getCachedRegUnit(*Units)) {
|
||||
SlotIndex Idx = LIS.getInstructionIndex(MI).getRegSlot();
|
||||
if (VNInfo *VNI = LI->getVNInfoAt(Idx))
|
||||
LI->removeValNo(VNI);
|
||||
if (VNInfo *VNI = LR->getVNInfoAt(Idx))
|
||||
LR->removeValNo(VNI);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user