summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2010-12-02 18:15:44 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2010-12-02 18:15:44 +0000
commit9ec20111c399e681afe05edd943db3096113bc10 (patch)
tree6bb419f19f7194bf3069fa7d1c34cd88bd8aeb39 /llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp
parent5f46b89df2cd1800e021dfe013944ac475720458 (diff)
downloadbcm5719-llvm-9ec20111c399e681afe05edd943db3096113bc10.tar.gz
bcm5719-llvm-9ec20111c399e681afe05edd943db3096113bc10.zip
Update LiveDebugVariables during coalescing.
llvm-svn: 120720
Diffstat (limited to 'llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp')
-rw-r--r--llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp b/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp
index bc5926c94dc..74e72af3293 100644
--- a/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp
+++ b/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp
@@ -696,6 +696,9 @@ SimpleRegisterCoalescing::UpdateRegDefsUses(const CoalescerPair &CP) {
unsigned DstReg = CP.getDstReg();
unsigned SubIdx = CP.getSubIdx();
+ // Update LiveDebugVariables.
+ ldv_->renameRegister(SrcReg, DstReg, SubIdx);
+
for (MachineRegisterInfo::reg_iterator I = mri_->reg_begin(SrcReg);
MachineInstr *UseMI = I.skipInstruction();) {
// A PhysReg copy that won't be coalesced can perhaps be rematerialized
@@ -1779,6 +1782,7 @@ bool SimpleRegisterCoalescing::runOnMachineFunction(MachineFunction &fn) {
}
DEBUG(dump());
+ DEBUG(ldv_->dump());
return true;
}
OpenPOWER on IntegriCloud