[llvm-commits] [llvm] r128145 - /llvm/trunk/lib/CodeGen/LiveRangeEdit.cpp

Jakob Stoklund Olesen stoklund at 2pi.dk
Tue Mar 22 21:43:16 PDT 2011


Author: stoklund
Date: Tue Mar 22 23:43:16 2011
New Revision: 128145

URL: http://llvm.org/viewvc/llvm-project?rev=128145&view=rev
Log:
Notify the delegate before removing dead values from a live interval.

The register allocator needs to know when the range shrinks.

Modified:
    llvm/trunk/lib/CodeGen/LiveRangeEdit.cpp

Modified: llvm/trunk/lib/CodeGen/LiveRangeEdit.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveRangeEdit.cpp?rev=128145&r1=128144&r2=128145&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/LiveRangeEdit.cpp (original)
+++ llvm/trunk/lib/CodeGen/LiveRangeEdit.cpp Tue Mar 22 23:43:16 2011
@@ -182,6 +182,8 @@
         // Remove defined value.
         if (MOI->isDef()) {
           if (VNInfo *VNI = LI.getVNInfoAt(Idx)) {
+            if (delegate_)
+              delegate_->LRE_WillShrinkVirtReg(LI.reg);
             LI.removeValNo(VNI);
             if (LI.empty()) {
               ToShrink.remove(&LI);





More information about the llvm-commits mailing list