[llvm-commits] [llvm] r44610 - /llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp

Evan Cheng evan.cheng at apple.com
Wed Dec 5 01:05:35 PST 2007


Author: evancheng
Date: Wed Dec  5 03:05:34 2007
New Revision: 44610

URL: http://llvm.org/viewvc/llvm-project?rev=44610&view=rev
Log:
Clobber more bugs.

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

Modified: llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp?rev=44610&r1=44609&r2=44610&view=diff

==============================================================================
--- llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp (original)
+++ llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp Wed Dec  5 03:05:34 2007
@@ -1221,7 +1221,6 @@
       // Original def may be modified so we have to make a copy here. vrm must
       // delete these!
       ReMatDefs[VN] = ReMatDefMI = ReMatDefMI->clone();
-      vrm.setVirtIsReMaterialized(li.reg, ReMatDefMI);
 
       bool CanDelete = true;
       if (VNI->hasPHIKill) {
@@ -1309,9 +1308,11 @@
         if (CanFold && !Ops.empty()) {
           if (tryFoldMemoryOperand(MI, vrm, NULL, index, Ops, true, Slot,VReg)){
             Folded = true;
-            if (FoundUse > 0)
+            if (FoundUse > 0) {
               // Also folded uses, do not issue a load.
               eraseRestoreInfo(Id, index, VReg, RestoreMBBs, RestoreIdxes);
+              nI.removeRange(getLoadIndex(index), getUseIndex(index)+1);
+            }
             nI.removeRange(getDefIndex(index), getStoreIndex(index));
           }
         }





More information about the llvm-commits mailing list