From 1e1098c6f39590e1e74e5cb3c2a1652d8f3cb16a Mon Sep 17 00:00:00 2001 From: Jakob Stoklund Olesen Date: Sat, 10 Jul 2010 22:42:59 +0000 Subject: Replace copyRegToReg with COPY everywhere in lib/CodeGen except for FastISel. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108062 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/MachineRegisterInfo.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'lib/CodeGen/MachineRegisterInfo.cpp') diff --git a/lib/CodeGen/MachineRegisterInfo.cpp b/lib/CodeGen/MachineRegisterInfo.cpp index 64a3753ab0..5d852f26be 100644 --- a/lib/CodeGen/MachineRegisterInfo.cpp +++ b/lib/CodeGen/MachineRegisterInfo.cpp @@ -194,12 +194,9 @@ MachineRegisterInfo::EmitLiveInCopies(MachineBasicBlock *EntryMBB, --i; --e; } else { // Emit a copy. - const TargetRegisterClass *RC = getRegClass(LiveIns[i].second); - bool Emitted = TII.copyRegToReg(*EntryMBB, EntryMBB->begin(), - LiveIns[i].second, LiveIns[i].first, - RC, RC, DebugLoc()); - assert(Emitted && "Unable to issue a live-in copy instruction!\n"); - (void) Emitted; + BuildMI(*EntryMBB, EntryMBB->begin(), DebugLoc(), + TII.get(TargetOpcode::COPY), LiveIns[i].second) + .addReg(LiveIns[i].first); // Add the register to the entry block live-in set. EntryMBB->addLiveIn(LiveIns[i].first); -- cgit v1.2.3