mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 11:42:57 +01:00
Restrict machine cse to really trivial coalescing. Leave the heavy lifting to a real coalescer.
llvm-svn: 98007
This commit is contained in:
parent
10d571f349
commit
ca86fb517c
@ -91,7 +91,10 @@ bool MachineCSE::PerformTrivialCoalescing(MachineInstr *MI,
|
||||
unsigned SrcReg, DstReg, SrcSubIdx, DstSubIdx;
|
||||
if (TII->isMoveInstr(*DefMI, SrcReg, DstReg, SrcSubIdx, DstSubIdx) &&
|
||||
TargetRegisterInfo::isVirtualRegister(SrcReg) &&
|
||||
MRI->getRegClass(SrcReg) == MRI->getRegClass(Reg) &&
|
||||
!SrcSubIdx && !DstSubIdx) {
|
||||
DEBUG(dbgs() << "Coalescing: " << *DefMI);
|
||||
DEBUG(dbgs() << "*** to: " << *MI);
|
||||
MO.setReg(SrcReg);
|
||||
DefMI->eraseFromParent();
|
||||
++NumCoalesces;
|
||||
|
Loading…
Reference in New Issue
Block a user