diff options
author | Chris Lattner <sabre@nondot.org> | 2006-01-29 06:44:22 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-01-29 06:44:22 +0000 |
commit | 44d9b9bb86cad2185b9229d67f84e57994f57a04 (patch) | |
tree | aef0673fa923d42a5536ac5c42e3bbd3d0936789 | |
parent | 8ca05e0c302e15d6365afd2a0ea5fe15c9e85758 (diff) |
The FP stack doesn't support UNDEF, ask the legalizer to legalize it
instead of lying and saying we have it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25775 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/X86/X86ISelLowering.cpp | 4 | ||||
-rw-r--r-- | lib/Target/X86/X86InstrInfo.td | 4 |
2 files changed, 3 insertions, 5 deletions
diff --git a/lib/Target/X86/X86ISelLowering.cpp b/lib/Target/X86/X86ISelLowering.cpp index 8a8161925b..9503bc13c4 100644 --- a/lib/Target/X86/X86ISelLowering.cpp +++ b/lib/Target/X86/X86ISelLowering.cpp @@ -221,7 +221,9 @@ X86TargetLowering::X86TargetLowering(TargetMachine &TM) } else { // Set up the FP register classes. addRegisterClass(MVT::f64, X86::RFPRegisterClass); - + + setOperationAction(ISD::UNDEF, MVT::f64, Expand); + if (!X86PatIsel) { setOperationAction(ISD::SINT_TO_FP, MVT::i16, Custom); setOperationAction(ISD::SINT_TO_FP, MVT::i32, Custom); diff --git a/lib/Target/X86/X86InstrInfo.td b/lib/Target/X86/X86InstrInfo.td index 8362a7e661..b3941b4fc5 100644 --- a/lib/Target/X86/X86InstrInfo.td +++ b/lib/Target/X86/X86InstrInfo.td @@ -3022,10 +3022,6 @@ def : Pat<(X86fst RFP:$src, addr:$op, f64), (FpST64m addr:$op, RFP:$src)>; def : Pat<(f64 fp64immneg0), (FpCHS (FpLD0))>, Requires<[FPStack]>; def : Pat<(f64 fp64immneg1), (FpCHS (FpLD1))>, Requires<[FPStack]>; -// RFP undef -def : Pat<(f64 (undef)), (FpLD0)>, Requires<[FPStack]>; - - //===----------------------------------------------------------------------===// // Some peepholes //===----------------------------------------------------------------------===// |