mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-05 09:24:28 +00:00
StrongPHIElimination doesn't support swapping live intervals like the coalescer does.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48802 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -866,15 +866,9 @@ void StrongPHIElimination::mergeLiveIntervals(unsigned primary,
|
|||||||
|
|
||||||
// If we get here, we know that we can coalesce the live ranges. Ask the
|
// If we get here, we know that we can coalesce the live ranges. Ask the
|
||||||
// intervals to coalesce themselves now.
|
// intervals to coalesce themselves now.
|
||||||
if ((RHS.ranges.size() > LHS.ranges.size() &&
|
|
||||||
TargetRegisterInfo::isVirtualRegister(LHS.reg)) ||
|
|
||||||
TargetRegisterInfo::isPhysicalRegister(RHS.reg)) {
|
|
||||||
RHS.join(LHS, &RHSValNoAssignments[0], &LHSValNoAssignments[0], NewVNInfo);
|
|
||||||
LI.removeInterval(primary);
|
|
||||||
} else {
|
|
||||||
LHS.join(RHS, &LHSValNoAssignments[0], &RHSValNoAssignments[0], NewVNInfo);
|
LHS.join(RHS, &LHSValNoAssignments[0], &RHSValNoAssignments[0], NewVNInfo);
|
||||||
LI.removeInterval(secondary);
|
LI.removeInterval(secondary);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool StrongPHIElimination::runOnMachineFunction(MachineFunction &Fn) {
|
bool StrongPHIElimination::runOnMachineFunction(MachineFunction &Fn) {
|
||||||
@ -921,5 +915,8 @@ bool StrongPHIElimination::runOnMachineFunction(MachineFunction &Fn) {
|
|||||||
(*I)->eraseFromParent();
|
(*I)->eraseFromParent();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
for (LiveIntervals::iterator I = LI.begin(), E = LI.end(); I != E; ++I)
|
||||||
|
I->second.dump();
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user