diff options
author | Craig Topper <craig.topper@intel.com> | 2019-10-31 13:37:57 -0700 |
---|---|---|
committer | Craig Topper <craig.topper@intel.com> | 2019-10-31 13:42:01 -0700 |
commit | a0aef632086781d7c67ab3c7ff0bbd019a2ba6c8 (patch) | |
tree | b838007bc7fec13bbb955e0c0bdd45169c49d61d /llvm/lib/Target/X86 | |
parent | d6bb256b443bc42ae626a5da5ccdd8460ad1003c (diff) | |
download | bcm5719-llvm-a0aef632086781d7c67ab3c7ff0bbd019a2ba6c8.tar.gz bcm5719-llvm-a0aef632086781d7c67ab3c7ff0bbd019a2ba6c8.zip |
[X86] Remove FSIN/FCOS isel patterns and the pseudo instructions that they selected for the FP stackifier.
We always expand these to libcalls so get rid of the last vestiges
of using the instructions.
Diffstat (limited to 'llvm/lib/Target/X86')
-rw-r--r-- | llvm/lib/Target/X86/X86FloatingPoint.cpp | 6 | ||||
-rw-r--r-- | llvm/lib/Target/X86/X86InstrFPStack.td | 7 | ||||
-rw-r--r-- | llvm/lib/Target/X86/X86ScheduleAtom.td | 3 |
3 files changed, 3 insertions, 13 deletions
diff --git a/llvm/lib/Target/X86/X86FloatingPoint.cpp b/llvm/lib/Target/X86/X86FloatingPoint.cpp index fcfb5bc9131..e54e3745f23 100644 --- a/llvm/lib/Target/X86/X86FloatingPoint.cpp +++ b/llvm/lib/Target/X86/X86FloatingPoint.cpp @@ -666,9 +666,6 @@ static const TableEntry OpcodeTable[] = { { X86::CMOVP_Fp32 , X86::CMOVP_F }, { X86::CMOVP_Fp64 , X86::CMOVP_F }, { X86::CMOVP_Fp80 , X86::CMOVP_F }, - { X86::COS_Fp32 , X86::COS_F }, - { X86::COS_Fp64 , X86::COS_F }, - { X86::COS_Fp80 , X86::COS_F }, { X86::DIVR_Fp32m , X86::DIVR_F32m }, { X86::DIVR_Fp64m , X86::DIVR_F64m }, { X86::DIVR_Fp64m32 , X86::DIVR_F32m }, @@ -741,9 +738,6 @@ static const TableEntry OpcodeTable[] = { { X86::MUL_FpI32m32 , X86::MUL_FI32m }, { X86::MUL_FpI32m64 , X86::MUL_FI32m }, { X86::MUL_FpI32m80 , X86::MUL_FI32m }, - { X86::SIN_Fp32 , X86::SIN_F }, - { X86::SIN_Fp64 , X86::SIN_F }, - { X86::SIN_Fp80 , X86::SIN_F }, { X86::SQRT_Fp32 , X86::SQRT_F }, { X86::SQRT_Fp64 , X86::SQRT_F }, { X86::SQRT_Fp80 , X86::SQRT_F }, diff --git a/llvm/lib/Target/X86/X86InstrFPStack.td b/llvm/lib/Target/X86/X86InstrFPStack.td index 2ec6d50f970..73cffc9aee4 100644 --- a/llvm/lib/Target/X86/X86InstrFPStack.td +++ b/llvm/lib/Target/X86/X86InstrFPStack.td @@ -369,11 +369,6 @@ defm ABS : FPUnary<fabs, MRM_E1, "fabs">; let SchedRW = [WriteFSqrt80] in defm SQRT: FPUnary<fsqrt,MRM_FA, "fsqrt">; -let SchedRW = [WriteMicrocoded] in { -defm SIN : FPUnary<fsin, MRM_FE, "fsin">; -defm COS : FPUnary<fcos, MRM_FF, "fcos">; -} - let SchedRW = [WriteFCom] in { let hasSideEffects = 0 in { def TST_Fp32 : FpIf32<(outs), (ins RFP32:$src), OneArgFP, []>; @@ -721,6 +716,8 @@ def FDECSTP : I<0xD9, MRM_F6, (outs), (ins), "fdecstp", []>; def FINCSTP : I<0xD9, MRM_F7, (outs), (ins), "fincstp", []>; def FPREM : I<0xD9, MRM_F8, (outs), (ins), "fprem", []>; def FYL2XP1 : I<0xD9, MRM_F9, (outs), (ins), "fyl2xp1", []>; +def FSIN : I<0xD9, MRM_FE, (outs), (ins), "fsin", []>; +def FCOS : I<0xD9, MRM_FF, (outs), (ins), "fcos", []>; def FSINCOS : I<0xD9, MRM_FB, (outs), (ins), "fsincos", []>; def FRNDINT : I<0xD9, MRM_FC, (outs), (ins), "frndint", []>; def FSCALE : I<0xD9, MRM_FD, (outs), (ins), "fscale", []>; diff --git a/llvm/lib/Target/X86/X86ScheduleAtom.td b/llvm/lib/Target/X86/X86ScheduleAtom.td index 78acb1065ec..b0153ca9da3 100644 --- a/llvm/lib/Target/X86/X86ScheduleAtom.td +++ b/llvm/lib/Target/X86/X86ScheduleAtom.td @@ -888,8 +888,7 @@ def AtomWrite01_174 : SchedWriteRes<[AtomPort01]> { let Latency = 174; let ResourceCycles = [174]; } -def : InstRW<[AtomWrite01_174], (instrs FSINCOS)>; -def : InstRW<[AtomWrite01_174], (instregex "(COS|SIN)_F")>; +def : InstRW<[AtomWrite01_174], (instrs FSINCOS, FSIN, FCOS)>; def AtomWrite01_183 : SchedWriteRes<[AtomPort01]> { let Latency = 183; |