Make another kill check LiveIntervals-aware.
authorCameron Zwarich <zwarich@apple.com>
Thu, 21 Feb 2013 07:02:30 +0000 (07:02 +0000)
committerCameron Zwarich <zwarich@apple.com>
Thu, 21 Feb 2013 07:02:30 +0000 (07:02 +0000)
This brings the number of remaining failures in 'make check' without
LiveVariables down to 39, with 1 unexpectedly passing test.

llvm-svn: 175727

llvm/lib/CodeGen/TwoAddressInstructionPass.cpp

index 8d242ec..e0dba3f 100644 (file)
@@ -499,7 +499,7 @@ isProfitableToCommute(unsigned regA, unsigned regB, unsigned regC,
   // insert => %reg1030<def> = MOV8rr %reg1029
   // %reg1030<def> = ADD8rr %reg1029<kill>, %reg1028<kill>, %EFLAGS<imp-def,dead>
 
-  if (!MI->killsRegister(regC))
+  if (!isPlainlyKilled(MI, regC, LIS))
     return false;
 
   // Ok, we have something like: