diff options
author | Lang Hames <lhames@gmail.com> | 2009-07-09 03:57:02 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2009-07-09 03:57:02 +0000 |
commit | dab7b06de971bffb7abced1ad1de9617311e3e8e (patch) | |
tree | 4e289365d7a57d4d96f20306fc40a9e0a546eccd /llvm/lib/CodeGen/LiveInterval.cpp | |
parent | 117608b129bded5b9cb0dc65051d014fbcaf8769 (diff) | |
download | bcm5719-llvm-dab7b06de971bffb7abced1ad1de9617311e3e8e.tar.gz bcm5719-llvm-dab7b06de971bffb7abced1ad1de9617311e3e8e.zip |
Improved tracking of value number kills. VN kills are now represented
as an (index,bool) pair. The bool flag records whether the kill is a
PHI kill or not. This code will be used to enable splitting of live
intervals containing PHI-kills.
A slight change to live interval weights introduced an extra spill
into lsr-code-insertion (outside the critical sections). The test
condition has been updated to reflect this.
llvm-svn: 75097
Diffstat (limited to 'llvm/lib/CodeGen/LiveInterval.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LiveInterval.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/LiveInterval.cpp b/llvm/lib/CodeGen/LiveInterval.cpp index 26722a3ca11..b786b1d85b0 100644 --- a/llvm/lib/CodeGen/LiveInterval.cpp +++ b/llvm/lib/CodeGen/LiveInterval.cpp @@ -377,8 +377,9 @@ void LiveInterval::scaleNumbering(unsigned factor) { vni->def = InstrSlots::scale(vni->def, factor); for (unsigned i = 0; i < vni->kills.size(); ++i) { - if (vni->kills[i] != 0) - vni->kills[i] = InstrSlots::scale(vni->kills[i], factor); + if (!vni->kills[i].isPHIKill) + vni->kills[i].killIdx = + InstrSlots::scale(vni->kills[i].killIdx, factor); } } } @@ -840,7 +841,9 @@ void LiveInterval::print(std::ostream &OS, if (ee || vni->hasPHIKill()) { OS << "-("; for (unsigned j = 0; j != ee; ++j) { - OS << vni->kills[j]; + OS << vni->kills[j].killIdx; + if (vni->kills[j].isPHIKill) + OS << "*"; if (j != ee-1) OS << " "; } |