[llvm] r175957 - Fix a bug with the LiveIntervals updating in the two-address pass found by

Cameron Zwarich zwarich at apple.com
Fri Feb 22 20:49:22 PST 2013


Author: zwarich
Date: Fri Feb 22 22:49:22 2013
New Revision: 175957

URL: http://llvm.org/viewvc/llvm-project?rev=175957&view=rev
Log:
Fix a bug with the LiveIntervals updating in the two-address pass found by
running ASCI_Purple/SMG2000 in the test-suite.

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

Modified: llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp?rev=175957&r1=175956&r2=175957&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp (original)
+++ llvm/trunk/lib/CodeGen/TwoAddressInstructionPass.cpp Fri Feb 22 22:49:22 2013
@@ -370,7 +370,7 @@ static bool isPlainlyKilled(MachineInstr
     SlotIndex useIdx = LIS->getInstructionIndex(MI);
     LiveInterval::const_iterator I = LI.find(useIdx);
     assert(I != LI.end() && "Reg must be live-in to use.");
-    return SlotIndex::isSameInstr(I->end, useIdx);
+    return !I->end.isBlock() && SlotIndex::isSameInstr(I->end, useIdx);
   }
 
   return MI->killsRegister(Reg);





More information about the llvm-commits mailing list