[llvm-commits] [llvm] r42655 - in /llvm/trunk: lib/Target/X86/X86InstrInfo.cpp test/CodeGen/X86/2006-05-02-InstrSched2.ll test/CodeGen/X86/2006-05-11-InstrSched.ll test/CodeGen/X86/loop-strength-reduce2.ll

Evan Cheng evan.cheng at apple.com
Fri Oct 5 15:31:10 PDT 2007


Author: evancheng
Date: Fri Oct  5 17:31:10 2007
New Revision: 42655

URL: http://llvm.org/viewvc/llvm-project?rev=42655&view=rev
Log:
Enable convertToThreeAddress for X86 by default.

Modified:
    llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
    llvm/trunk/test/CodeGen/X86/2006-05-02-InstrSched2.ll
    llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll
    llvm/trunk/test/CodeGen/X86/loop-strength-reduce2.ll

Modified: llvm/trunk/lib/Target/X86/X86InstrInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrInfo.cpp?rev=42655&r1=42654&r2=42655&view=diff

==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrInfo.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86InstrInfo.cpp Fri Oct  5 17:31:10 2007
@@ -22,15 +22,8 @@
 #include "llvm/CodeGen/LiveVariables.h"
 #include "llvm/CodeGen/SSARegMap.h"
 #include "llvm/Target/TargetOptions.h"
-#include "llvm/Support/CommandLine.h"
 using namespace llvm;
 
-namespace {
-  cl::opt<bool>
-  EnableConvert3Addr("enable-x86-conv-3-addr",
-           cl::desc("Enable convertToThreeAddress for X86"));
-}
-
 X86InstrInfo::X86InstrInfo(X86TargetMachine &tm)
   : TargetInstrInfo(X86Insts, array_lengthof(X86Insts)),
     TM(tm), RI(tm, *this) {
@@ -154,8 +147,6 @@
 /// hasLiveCondCodeDef - True if MI has a condition code def, e.g. EFLAGS, that
 /// is not marked dead.
 static bool hasLiveCondCodeDef(MachineInstr *MI) {
-  if (!EnableConvert3Addr)
-    return true;
   for (unsigned i = 0, e = MI->getNumOperands(); i != e; ++i) {
     MachineOperand &MO = MI->getOperand(i);
     if (MO.isRegister() && MO.isDef() &&

Modified: llvm/trunk/test/CodeGen/X86/2006-05-02-InstrSched2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2006-05-02-InstrSched2.ll?rev=42655&r1=42654&r2=42655&view=diff

==============================================================================
--- llvm/trunk/test/CodeGen/X86/2006-05-02-InstrSched2.ll (original)
+++ llvm/trunk/test/CodeGen/X86/2006-05-02-InstrSched2.ll Fri Oct  5 17:31:10 2007
@@ -1,5 +1,5 @@
 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -stats |& \
-; RUN:   grep asm-printer | grep 16
+; RUN:   grep asm-printer | grep 15
 
 void %_ZN9__gnu_cxx9hashtableISt4pairIKPKciES3_NS_4hashIS3_EESt10_Select1stIS5_E5eqstrSaIiEE14find_or_insertERKS5__cond_true456.i(sbyte* %tmp435.i, uint* %tmp449.i.out) {
 newFuncRoot:

Modified: llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll?rev=42655&r1=42654&r2=42655&view=diff

==============================================================================
--- llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll (original)
+++ llvm/trunk/test/CodeGen/X86/2006-05-11-InstrSched.ll Fri Oct  5 17:31:10 2007
@@ -1,5 +1,5 @@
 ; RUN: llvm-as < %s | llc -march=x86 -mattr=+sse2 -stats |&\
-; RUN:     grep {asm-printer} | grep 33
+; RUN:     grep {asm-printer} | grep 32
 
 target datalayout = "e-p:32:32"
 define void @foo(i32* %mc, i32* %bp, i32* %ms, i32* %xmb, i32* %mpp, i32* %tpmm, i32* %ip, i32* %tpim, i32* %dpp, i32* %tpdm, i32* %bpi, i32 %M) {

Modified: llvm/trunk/test/CodeGen/X86/loop-strength-reduce2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/loop-strength-reduce2.ll?rev=42655&r1=42654&r2=42655&view=diff

==============================================================================
--- llvm/trunk/test/CodeGen/X86/loop-strength-reduce2.ll (original)
+++ llvm/trunk/test/CodeGen/X86/loop-strength-reduce2.ll Fri Oct  5 17:31:10 2007
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=i686-apple-darwin -relocation-model=pic | not grep lea
+; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=i686-apple-darwin -relocation-model=pic | grep '\$pb' | grep mov
 ;
 ; Make sure the PIC label flags2-"L1$pb" is not moved up to the preheader.
 





More information about the llvm-commits mailing list