[llvm-commits] [llvm] r83421 - /llvm/trunk/lib/Target/ARM/NEONPreAllocPass.cpp
Bob Wilson
bob.wilson at apple.com
Tue Oct 6 15:01:16 PDT 2009
Author: bwilson
Date: Tue Oct 6 17:01:15 2009
New Revision: 83421
URL: http://llvm.org/viewvc/llvm-project?rev=83421&view=rev
Log:
Use copyRegToReg hook to copy registers.
Modified:
llvm/trunk/lib/Target/ARM/NEONPreAllocPass.cpp
Modified: llvm/trunk/lib/Target/ARM/NEONPreAllocPass.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/NEONPreAllocPass.cpp?rev=83421&r1=83420&r2=83421&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/NEONPreAllocPass.cpp (original)
+++ llvm/trunk/lib/Target/ARM/NEONPreAllocPass.cpp Tue Oct 6 17:01:15 2009
@@ -163,9 +163,8 @@
if (MO.isUse()) {
// Insert a copy from VirtReg.
- AddDefaultPred(BuildMI(MBB, MBBI, MI->getDebugLoc(),
- TII->get(ARM::FCPYD), MO.getReg())
- .addReg(VirtReg));
+ TII->copyRegToReg(MBB, MBBI, MO.getReg(), VirtReg,
+ ARM::DPRRegisterClass, ARM::DPRRegisterClass);
if (MO.isKill()) {
MachineInstr *CopyMI = prior(MBBI);
CopyMI->findRegisterUseOperand(VirtReg)->setIsKill();
@@ -173,9 +172,8 @@
MO.setIsKill();
} else if (MO.isDef() && !MO.isDead()) {
// Add a copy to VirtReg.
- AddDefaultPred(BuildMI(MBB, NextI, MI->getDebugLoc(),
- TII->get(ARM::FCPYD), VirtReg)
- .addReg(MO.getReg()));
+ TII->copyRegToReg(MBB, NextI, VirtReg, MO.getReg(),
+ ARM::DPRRegisterClass, ARM::DPRRegisterClass);
}
}
}
More information about the llvm-commits
mailing list