aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorOwen Anderson <resistor@mac.com>2009-01-21 00:13:28 +0000
committerOwen Anderson <resistor@mac.com>2009-01-21 00:13:28 +0000
commit6cf7c390ecf33cdbe9e65d230e4f61ac548893e6 (patch)
tree7f92f3d67cc3691f1b81daa7758fa2dea10f2267 /lib
parent476615934a74a313a691413230d249889cfaa2f8 (diff)
downloadexternal_llvm-6cf7c390ecf33cdbe9e65d230e4f61ac548893e6.zip
external_llvm-6cf7c390ecf33cdbe9e65d230e4f61ac548893e6.tar.gz
external_llvm-6cf7c390ecf33cdbe9e65d230e4f61ac548893e6.tar.bz2
Be more aggressive about renumbering vregs after splitting them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62639 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/PreAllocSplitting.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/CodeGen/PreAllocSplitting.cpp b/lib/CodeGen/PreAllocSplitting.cpp
index 6b37637..3c8257f 100644
--- a/lib/CodeGen/PreAllocSplitting.cpp
+++ b/lib/CodeGen/PreAllocSplitting.cpp
@@ -1127,9 +1127,11 @@ bool PreAllocSplitting::Rematerialize(unsigned vreg, VNInfo* ValNo,
LIs->InsertMachineInstrInMaps(prior(RestorePt), RestoreIdx);
if (KillPt->getParent() == BarrierMBB) {
- UpdateRegisterInterval(ValNo, LIs->getUseIndex(KillIdx)+1,
+ VNInfo* After = UpdateRegisterInterval(ValNo, LIs->getUseIndex(KillIdx)+1,
LIs->getDefIndex(RestoreIdx));
+ RenumberValno(After);
+
++NumSplits;
++NumRemats;
return true;
@@ -1312,9 +1314,11 @@ bool PreAllocSplitting::SplitRegLiveInterval(LiveInterval *LI) {
UpdateSpillSlotInterval(ValNo, LIs->getUseIndex(SpillIndex)+1,
LIs->getDefIndex(RestoreIndex));
- UpdateRegisterInterval(ValNo, LIs->getUseIndex(SpillIndex)+1,
+ VNInfo* After = UpdateRegisterInterval(ValNo,
+ LIs->getUseIndex(SpillIndex)+1,
LIs->getDefIndex(RestoreIndex));
-
+ RenumberValno(After);
+
++NumSplits;
return true;
}