summaryrefslogtreecommitdiff
path: root/lib/CodeGen/MachineRegisterInfo.cpp
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2010-07-10 22:42:59 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2010-07-10 22:42:59 +0000
commit1e1098c6f39590e1e74e5cb3c2a1652d8f3cb16a (patch)
treef9ffe20d3fa8cb97c561660a19b78a9641316d5a /lib/CodeGen/MachineRegisterInfo.cpp
parentc0075cce7cf6682af8a09126709106866b2f5971 (diff)
downloadllvm-1e1098c6f39590e1e74e5cb3c2a1652d8f3cb16a.tar.gz
llvm-1e1098c6f39590e1e74e5cb3c2a1652d8f3cb16a.tar.bz2
llvm-1e1098c6f39590e1e74e5cb3c2a1652d8f3cb16a.tar.xz
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
Diffstat (limited to 'lib/CodeGen/MachineRegisterInfo.cpp')
-rw-r--r--lib/CodeGen/MachineRegisterInfo.cpp9
1 files changed, 3 insertions, 6 deletions
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);