Skip to content

Commit 7a3aabf

Browse files
committed
remove llvm specific code
1 parent 62c8e95 commit 7a3aabf

32 files changed

+12
-452
lines changed

llvm/docs/GlobalISel/GenericOpcode.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -592,8 +592,8 @@ G_FLOG, G_FLOG2, G_FLOG10
592592

593593
Calculate the base-e, base-2, or base-10 respectively.
594594

595-
G_FCEIL, G_FCOS, G_FSIN, G_FTAN, G_FSQRT, G_FFLOOR, G_FRINT, G_FNEARBYINT
596-
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
595+
G_FCEIL, G_FCOS, G_FSIN, G_FSQRT, G_FFLOOR, G_FRINT, G_FNEARBYINT
596+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
597597

598598
These correspond to the standard C functions of the same name.
599599

llvm/include/llvm/Analysis/VecFuncs.def

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ TLI_DEFINE_VECFUNC("llvm.sin.f32", "vsinf", FIXED(4), "_ZGV_LLVM_N4v")
5454
TLI_DEFINE_VECFUNC("cosf", "vcosf", FIXED(4), "_ZGV_LLVM_N4v")
5555
TLI_DEFINE_VECFUNC("llvm.cos.f32", "vcosf", FIXED(4), "_ZGV_LLVM_N4v")
5656
TLI_DEFINE_VECFUNC("tanf", "vtanf", FIXED(4), "_ZGV_LLVM_N4v")
57-
TLI_DEFINE_VECFUNC("llvm.tan.f32", "vtanf", FIXED(4), "_ZGV_LLVM_N4v")
5857
TLI_DEFINE_VECFUNC("asinf", "vasinf", FIXED(4), "_ZGV_LLVM_N4v")
5958
TLI_DEFINE_VECFUNC("acosf", "vacosf", FIXED(4), "_ZGV_LLVM_N4v")
6059
TLI_DEFINE_VECFUNC("atanf", "vatanf", FIXED(4), "_ZGV_LLVM_N4v")

llvm/include/llvm/CodeGen/BasicTTIImpl.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1924,9 +1924,6 @@ class BasicTTIImplBase : public TargetTransformInfoImplCRTPBase<T> {
19241924
case Intrinsic::cos:
19251925
ISD = ISD::FCOS;
19261926
break;
1927-
case Intrinsic::tan:
1928-
ISD = ISD::FTAN;
1929-
break;
19301927
case Intrinsic::exp:
19311928
ISD = ISD::FEXP;
19321929
break;

llvm/include/llvm/CodeGen/ISDOpcodes.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,6 @@ enum NodeType {
415415
STRICT_FLDEXP,
416416
STRICT_FSIN,
417417
STRICT_FCOS,
418-
STRICT_FTAN,
419418
STRICT_FEXP,
420419
STRICT_FEXP2,
421420
STRICT_FLOG,
@@ -935,7 +934,6 @@ enum NodeType {
935934
FCBRT,
936935
FSIN,
937936
FCOS,
938-
FTAN,
939937
FPOW,
940938
FPOWI,
941939
/// FLDEXP - ldexp, inspired by libm (op0 * 2**op1).

llvm/include/llvm/IR/RuntimeLibcalls.def

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -197,11 +197,6 @@ HANDLE_LIBCALL(COS_F64, "cos")
197197
HANDLE_LIBCALL(COS_F80, "cosl")
198198
HANDLE_LIBCALL(COS_F128, "cosl")
199199
HANDLE_LIBCALL(COS_PPCF128, "cosl")
200-
HANDLE_LIBCALL(TAN_F32, "tanf")
201-
HANDLE_LIBCALL(TAN_F64, "tan")
202-
HANDLE_LIBCALL(TAN_F80, "tanl")
203-
HANDLE_LIBCALL(TAN_F128,"tanl")
204-
HANDLE_LIBCALL(TAN_PPCF128, "tanl")
205200
HANDLE_LIBCALL(SINCOS_F32, nullptr)
206201
HANDLE_LIBCALL(SINCOS_F64, nullptr)
207202
HANDLE_LIBCALL(SINCOS_F80, nullptr)

llvm/include/llvm/Support/TargetOpcodes.def

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -781,9 +781,6 @@ HANDLE_TARGET_OPCODE(G_FCOS)
781781
/// Floating point sine.
782782
HANDLE_TARGET_OPCODE(G_FSIN)
783783

784-
/// Floating point Tangent.
785-
HANDLE_TARGET_OPCODE(G_FTAN)
786-
787784
/// Floating point square root.
788785
HANDLE_TARGET_OPCODE(G_FSQRT)
789786

llvm/include/llvm/Target/GenericOpcodes.td

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -988,13 +988,6 @@ def G_FSIN : GenericInstruction {
988988
let hasSideEffects = false;
989989
}
990990

991-
// Floating point tangent of a value.
992-
def G_FTAN : GenericInstruction {
993-
let OutOperandList = (outs type0:$dst);
994-
let InOperandList = (ins type0:$src1);
995-
let hasSideEffects = false;
996-
}
997-
998991
// Floating point square root of a value.
999992
// This returns NaN for negative nonzero values.
1000993
// NOTE: Unlike libm sqrt(), this never sets errno. In all other respects it's

llvm/include/llvm/Target/GlobalISel/SelectionDAGCompat.td

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,6 @@ def : GINodeEquiv<G_BUILD_VECTOR, build_vector>;
148148
def : GINodeEquiv<G_FCEIL, fceil>;
149149
def : GINodeEquiv<G_FCOS, fcos>;
150150
def : GINodeEquiv<G_FSIN, fsin>;
151-
def : GINodeEquiv<G_FTAN, ftan>;
152151
def : GINodeEquiv<G_FABS, fabs>;
153152
def : GINodeEquiv<G_FSQRT, fsqrt>;
154153
def : GINodeEquiv<G_FFLOOR, ffloor>;

llvm/include/llvm/Target/TargetSelectionDAG.td

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,6 @@ def fneg : SDNode<"ISD::FNEG" , SDTFPUnaryOp>;
509509
def fsqrt : SDNode<"ISD::FSQRT" , SDTFPUnaryOp>;
510510
def fsin : SDNode<"ISD::FSIN" , SDTFPUnaryOp>;
511511
def fcos : SDNode<"ISD::FCOS" , SDTFPUnaryOp>;
512-
def ftan : SDNode<"ISD::FTAN" , SDTFPUnaryOp>;
513512
def fexp2 : SDNode<"ISD::FEXP2" , SDTFPUnaryOp>;
514513
def fexp10 : SDNode<"ISD::FEXP10" , SDTFPUnaryOp>;
515514
def fpow : SDNode<"ISD::FPOW" , SDTFPBinOp>;
@@ -563,8 +562,6 @@ def strict_fsin : SDNode<"ISD::STRICT_FSIN",
563562
SDTFPUnaryOp, [SDNPHasChain]>;
564563
def strict_fcos : SDNode<"ISD::STRICT_FCOS",
565564
SDTFPUnaryOp, [SDNPHasChain]>;
566-
def strict_ftan : SDNode<"ISD::STRICT_FTAN",
567-
SDTFPUnaryOp, [SDNPHasChain]>;
568565
def strict_fexp2 : SDNode<"ISD::STRICT_FEXP2",
569566
SDTFPUnaryOp, [SDNPHasChain]>;
570567
def strict_fpow : SDNode<"ISD::STRICT_FPOW",
@@ -1517,9 +1514,6 @@ def any_fsin : PatFrags<(ops node:$src),
15171514
def any_fcos : PatFrags<(ops node:$src),
15181515
[(strict_fcos node:$src),
15191516
(fcos node:$src)]>;
1520-
def any_ftan : PatFrags<(ops node:$src),
1521-
[(strict_ftan node:$src),
1522-
(ftan node:$src)]>;
15231517
def any_fexp2 : PatFrags<(ops node:$src),
15241518
[(strict_fexp2 node:$src),
15251519
(fexp2 node:$src)]>;

llvm/lib/Analysis/VectorUtils.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ bool llvm::isTriviallyVectorizable(Intrinsic::ID ID) {
6868
case Intrinsic::sqrt: // Begin floating-point.
6969
case Intrinsic::sin:
7070
case Intrinsic::cos:
71-
case Intrinsic::tan:
7271
case Intrinsic::exp:
7372
case Intrinsic::exp2:
7473
case Intrinsic::log:

llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1945,8 +1945,6 @@ unsigned IRTranslator::getSimpleIntrinsicOpcode(Intrinsic::ID ID) {
19451945
return TargetOpcode::G_FSIN;
19461946
case Intrinsic::sqrt:
19471947
return TargetOpcode::G_FSQRT;
1948-
case Intrinsic::tan:
1949-
return TargetOpcode::G_FTAN;
19501948
case Intrinsic::trunc:
19511949
return TargetOpcode::G_INTRINSIC_TRUNC;
19521950
case Intrinsic::readcyclecounter:

llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -448,8 +448,6 @@ static RTLIB::Libcall getRTLibDesc(unsigned Opcode, unsigned Size) {
448448
RTLIBCASE(SIN_F);
449449
case TargetOpcode::G_FCOS:
450450
RTLIBCASE(COS_F);
451-
case TargetOpcode::G_FTAN:
452-
RTLIBCASE(TAN_F);
453451
case TargetOpcode::G_FLOG10:
454452
RTLIBCASE(LOG10_F);
455453
case TargetOpcode::G_FLOG:
@@ -1038,7 +1036,6 @@ LegalizerHelper::libcall(MachineInstr &MI, LostDebugLocObserver &LocObserver) {
10381036
case TargetOpcode::G_FREM:
10391037
case TargetOpcode::G_FCOS:
10401038
case TargetOpcode::G_FSIN:
1041-
case TargetOpcode::G_FTAN:
10421039
case TargetOpcode::G_FLOG10:
10431040
case TargetOpcode::G_FLOG:
10441041
case TargetOpcode::G_FLOG2:
@@ -2893,7 +2890,6 @@ LegalizerHelper::widenScalar(MachineInstr &MI, unsigned TypeIdx, LLT WideTy) {
28932890
case TargetOpcode::G_FFLOOR:
28942891
case TargetOpcode::G_FCOS:
28952892
case TargetOpcode::G_FSIN:
2896-
case TargetOpcode::G_FTAN:
28972893
case TargetOpcode::G_FLOG10:
28982894
case TargetOpcode::G_FLOG:
28992895
case TargetOpcode::G_FLOG2:
@@ -4660,7 +4656,6 @@ LegalizerHelper::fewerElementsVector(MachineInstr &MI, unsigned TypeIdx,
46604656
case G_INTRINSIC_TRUNC:
46614657
case G_FCOS:
46624658
case G_FSIN:
4663-
case G_FTAN:
46644659
case G_FSQRT:
46654660
case G_BSWAP:
46664661
case G_BITREVERSE:

llvm/lib/CodeGen/GlobalISel/Utils.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -819,7 +819,6 @@ bool llvm::isKnownNeverNaN(Register Val, const MachineRegisterInfo &MRI,
819819
case TargetOpcode::G_FREM:
820820
case TargetOpcode::G_FSIN:
821821
case TargetOpcode::G_FCOS:
822-
case TargetOpcode::G_FTAN:
823822
case TargetOpcode::G_FMA:
824823
case TargetOpcode::G_FMAD:
825824
if (SNaN)
@@ -1700,7 +1699,6 @@ bool llvm::isPreISelGenericFloatingPointOpcode(unsigned Opc) {
17001699
case TargetOpcode::G_FREM:
17011700
case TargetOpcode::G_FRINT:
17021701
case TargetOpcode::G_FSIN:
1703-
case TargetOpcode::G_FTAN:
17041702
case TargetOpcode::G_FSQRT:
17051703
case TargetOpcode::G_FSUB:
17061704
case TargetOpcode::G_INTRINSIC_ROUND:

llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4423,11 +4423,6 @@ void SelectionDAGLegalize::ConvertNodeToLibcall(SDNode *Node) {
44234423
RTLIB::COS_F80, RTLIB::COS_F128,
44244424
RTLIB::COS_PPCF128, Results);
44254425
break;
4426-
case ISD::FTAN:
4427-
case ISD::STRICT_FTAN:
4428-
ExpandFPLibCall(Node, RTLIB::TAN_F32, RTLIB::TAN_F64, RTLIB::TAN_F80,
4429-
RTLIB::TAN_F128, RTLIB::TAN_PPCF128, Results);
4430-
break;
44314426
case ISD::FSINCOS:
44324427
// Expand into sincos libcall.
44334428
ExpandSinCosLibCall(Node, Results);
@@ -5372,7 +5367,6 @@ void SelectionDAGLegalize::PromoteNode(SDNode *Node) {
53725367
case ISD::FSQRT:
53735368
case ISD::FSIN:
53745369
case ISD::FCOS:
5375-
case ISD::FTAN:
53765370
case ISD::FLOG:
53775371
case ISD::FLOG2:
53785372
case ISD::FLOG10:
@@ -5397,7 +5391,6 @@ void SelectionDAGLegalize::PromoteNode(SDNode *Node) {
53975391
case ISD::STRICT_FSQRT:
53985392
case ISD::STRICT_FSIN:
53995393
case ISD::STRICT_FCOS:
5400-
case ISD::STRICT_FTAN:
54015394
case ISD::STRICT_FLOG:
54025395
case ISD::STRICT_FLOG2:
54035396
case ISD::STRICT_FLOG10:

llvm/lib/CodeGen/SelectionDAG/LegalizeFloatTypes.cpp

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,6 @@ void DAGTypeLegalizer::SoftenFloatResult(SDNode *N, unsigned ResNo) {
131131
case ISD::FSQRT: R = SoftenFloatRes_FSQRT(N); break;
132132
case ISD::STRICT_FSUB:
133133
case ISD::FSUB: R = SoftenFloatRes_FSUB(N); break;
134-
case ISD::STRICT_FTAN:
135-
case ISD::FTAN: R = SoftenFloatRes_FTAN(N); break;
136134
case ISD::STRICT_FTRUNC:
137135
case ISD::FTRUNC: R = SoftenFloatRes_FTRUNC(N); break;
138136
case ISD::LOAD: R = SoftenFloatRes_LOAD(N); break;
@@ -775,12 +773,6 @@ SDValue DAGTypeLegalizer::SoftenFloatRes_FSUB(SDNode *N) {
775773
RTLIB::SUB_PPCF128));
776774
}
777775

778-
SDValue DAGTypeLegalizer::SoftenFloatRes_FTAN(SDNode *N) {
779-
return SoftenFloatRes_Unary(
780-
N, GetFPLibCall(N->getValueType(0), RTLIB::TAN_F32, RTLIB::TAN_F64,
781-
RTLIB::TAN_F80, RTLIB::TAN_F128, RTLIB::TAN_PPCF128));
782-
}
783-
784776
SDValue DAGTypeLegalizer::SoftenFloatRes_FTRUNC(SDNode *N) {
785777
return SoftenFloatRes_Unary(N, GetFPLibCall(N->getValueType(0),
786778
RTLIB::TRUNC_F32,
@@ -1369,10 +1361,6 @@ void DAGTypeLegalizer::ExpandFloatResult(SDNode *N, unsigned ResNo) {
13691361
case ISD::FSQRT: ExpandFloatRes_FSQRT(N, Lo, Hi); break;
13701362
case ISD::STRICT_FSUB:
13711363
case ISD::FSUB: ExpandFloatRes_FSUB(N, Lo, Hi); break;
1372-
case ISD::STRICT_FTAN:
1373-
case ISD::FTAN:
1374-
ExpandFloatRes_FTAN(N, Lo, Hi);
1375-
break;
13761364
case ISD::STRICT_FTRUNC:
13771365
case ISD::FTRUNC: ExpandFloatRes_FTRUNC(N, Lo, Hi); break;
13781366
case ISD::LOAD: ExpandFloatRes_LOAD(N, Lo, Hi); break;
@@ -1742,15 +1730,6 @@ void DAGTypeLegalizer::ExpandFloatRes_FSUB(SDNode *N, SDValue &Lo,
17421730
RTLIB::SUB_PPCF128), Lo, Hi);
17431731
}
17441732

1745-
void DAGTypeLegalizer::ExpandFloatRes_FTAN(SDNode *N, SDValue &Lo,
1746-
SDValue &Hi) {
1747-
ExpandFloatRes_Unary(N,
1748-
GetFPLibCall(N->getValueType(0), RTLIB::TAN_F32,
1749-
RTLIB::TAN_F64, RTLIB::TAN_F80,
1750-
RTLIB::TAN_F128, RTLIB::TAN_PPCF128),
1751-
Lo, Hi);
1752-
}
1753-
17541733
void DAGTypeLegalizer::ExpandFloatRes_FTRUNC(SDNode *N,
17551734
SDValue &Lo, SDValue &Hi) {
17561735
ExpandFloatRes_Unary(N, GetFPLibCall(N->getValueType(0),
@@ -2444,7 +2423,6 @@ void DAGTypeLegalizer::PromoteFloatResult(SDNode *N, unsigned ResNo) {
24442423
case ISD::FSIN:
24452424
case ISD::FSQRT:
24462425
case ISD::FTRUNC:
2447-
case ISD::FTAN:
24482426
case ISD::FCANONICALIZE: R = PromoteFloatRes_UnaryOp(N); break;
24492427

24502428
// Binary FP Operations
@@ -2876,7 +2854,6 @@ void DAGTypeLegalizer::SoftPromoteHalfResult(SDNode *N, unsigned ResNo) {
28762854
case ISD::FSIN:
28772855
case ISD::FSQRT:
28782856
case ISD::FTRUNC:
2879-
case ISD::FTAN:
28802857
case ISD::FCANONICALIZE: R = SoftPromoteHalfRes_UnaryOp(N); break;
28812858

28822859
// Binary FP Operations

llvm/lib/CodeGen/SelectionDAG/LegalizeTypes.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -566,7 +566,6 @@ class LLVM_LIBRARY_VISIBILITY DAGTypeLegalizer {
566566
SDValue SoftenFloatRes_FSIN(SDNode *N);
567567
SDValue SoftenFloatRes_FSQRT(SDNode *N);
568568
SDValue SoftenFloatRes_FSUB(SDNode *N);
569-
SDValue SoftenFloatRes_FTAN(SDNode *N);
570569
SDValue SoftenFloatRes_FTRUNC(SDNode *N);
571570
SDValue SoftenFloatRes_LOAD(SDNode *N);
572571
SDValue SoftenFloatRes_SELECT(SDNode *N);
@@ -646,7 +645,6 @@ class LLVM_LIBRARY_VISIBILITY DAGTypeLegalizer {
646645
void ExpandFloatRes_FSIN (SDNode *N, SDValue &Lo, SDValue &Hi);
647646
void ExpandFloatRes_FSQRT (SDNode *N, SDValue &Lo, SDValue &Hi);
648647
void ExpandFloatRes_FSUB (SDNode *N, SDValue &Lo, SDValue &Hi);
649-
void ExpandFloatRes_FTAN(SDNode *N, SDValue &Lo, SDValue &Hi);
650648
void ExpandFloatRes_FTRUNC (SDNode *N, SDValue &Lo, SDValue &Hi);
651649
void ExpandFloatRes_LOAD (SDNode *N, SDValue &Lo, SDValue &Hi);
652650
void ExpandFloatRes_XINT_TO_FP(SDNode *N, SDValue &Lo, SDValue &Hi);

llvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,6 @@ SDValue VectorLegalizer::LegalizeOp(SDValue Op) {
402402
case ISD::FSQRT:
403403
case ISD::FSIN:
404404
case ISD::FCOS:
405-
case ISD::FTAN:
406405
case ISD::FLDEXP:
407406
case ISD::FPOWI:
408407
case ISD::FPOW:

llvm/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,6 @@ void DAGTypeLegalizer::ScalarizeVectorResult(SDNode *N, unsigned ResNo) {
107107
case ISD::FROUNDEVEN:
108108
case ISD::FSIN:
109109
case ISD::FSQRT:
110-
case ISD::FTAN:
111110
case ISD::FTRUNC:
112111
case ISD::SIGN_EXTEND:
113112
case ISD::SINT_TO_FP:
@@ -1112,7 +1111,6 @@ void DAGTypeLegalizer::SplitVectorResult(SDNode *N, unsigned ResNo) {
11121111
case ISD::VP_FROUNDEVEN:
11131112
case ISD::FSIN:
11141113
case ISD::FSQRT: case ISD::VP_SQRT:
1115-
case ISD::FTAN:
11161114
case ISD::FTRUNC:
11171115
case ISD::VP_FROUNDTOZERO:
11181116
case ISD::SINT_TO_FP:
@@ -4310,7 +4308,6 @@ void DAGTypeLegalizer::WidenVectorResult(SDNode *N, unsigned ResNo) {
43104308
case ISD::FROUNDEVEN:
43114309
case ISD::FSIN:
43124310
case ISD::FSQRT:
4313-
case ISD::FTAN:
43144311
case ISD::FTRUNC:
43154312
if (unrollExpandedOp())
43164313
break;

llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5255,7 +5255,6 @@ bool SelectionDAG::isKnownNeverNaN(SDValue Op, bool SNaN, unsigned Depth) const
52555255
case ISD::FREM:
52565256
case ISD::FSIN:
52575257
case ISD::FCOS:
5258-
case ISD::FTAN:
52595258
case ISD::FMA:
52605259
case ISD::FMAD: {
52615260
if (SNaN)

llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6690,7 +6690,6 @@ void SelectionDAGBuilder::visitIntrinsicCall(const CallInst &I,
66906690
case Intrinsic::fabs:
66916691
case Intrinsic::sin:
66926692
case Intrinsic::cos:
6693-
case Intrinsic::tan:
66946693
case Intrinsic::exp10:
66956694
case Intrinsic::floor:
66966695
case Intrinsic::ceil:
@@ -6707,9 +6706,6 @@ void SelectionDAGBuilder::visitIntrinsicCall(const CallInst &I,
67076706
case Intrinsic::fabs: Opcode = ISD::FABS; break;
67086707
case Intrinsic::sin: Opcode = ISD::FSIN; break;
67096708
case Intrinsic::cos: Opcode = ISD::FCOS; break;
6710-
case Intrinsic::tan:
6711-
Opcode = ISD::FTAN;
6712-
break;
67136709
case Intrinsic::exp10: Opcode = ISD::FEXP10; break;
67146710
case Intrinsic::floor: Opcode = ISD::FFLOOR; break;
67156711
case Intrinsic::ceil: Opcode = ISD::FCEIL; break;
@@ -9085,12 +9081,6 @@ void SelectionDAGBuilder::visitCall(const CallInst &I) {
90859081
if (visitUnaryFloatCall(I, ISD::FCOS))
90869082
return;
90879083
break;
9088-
case LibFunc_tan:
9089-
case LibFunc_tanf:
9090-
case LibFunc_tanl:
9091-
if (visitUnaryFloatCall(I, ISD::FTAN))
9092-
return;
9093-
break;
90949084
case LibFunc_sqrt:
90959085
case LibFunc_sqrtf:
90969086
case LibFunc_sqrtl:

llvm/lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,8 +210,6 @@ std::string SDNode::getOperationName(const SelectionDAG *G) const {
210210
case ISD::FCOS: return "fcos";
211211
case ISD::STRICT_FCOS: return "strict_fcos";
212212
case ISD::FSINCOS: return "fsincos";
213-
case ISD::FTAN: return "ftan";
214-
case ISD::STRICT_FTAN: return "strict_ftan";
215213
case ISD::FTRUNC: return "ftrunc";
216214
case ISD::STRICT_FTRUNC: return "strict_ftrunc";
217215
case ISD::FFLOOR: return "ffloor";

llvm/lib/CodeGen/TargetLoweringBase.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,6 @@ void TargetLoweringBase::InitLibcalls(const Triple &TT) {
141141
setLibcallName(RTLIB::EXP10_F128, "exp10f128");
142142
setLibcallName(RTLIB::SIN_F128, "sinf128");
143143
setLibcallName(RTLIB::COS_F128, "cosf128");
144-
setLibcallName(RTLIB::TAN_F128, "tanf128");
145144
setLibcallName(RTLIB::SINCOS_F128, "sincosf128");
146145
setLibcallName(RTLIB::POW_F128, "powf128");
147146
setLibcallName(RTLIB::POW_FINITE_F128, "__powf128_finite");
@@ -988,8 +987,7 @@ void TargetLoweringBase::initActions() {
988987
setOperationAction({ISD::FCBRT, ISD::FLOG, ISD::FLOG2, ISD::FLOG10, ISD::FEXP,
989988
ISD::FEXP2, ISD::FEXP10, ISD::FFLOOR, ISD::FNEARBYINT,
990989
ISD::FCEIL, ISD::FRINT, ISD::FTRUNC, ISD::LROUND,
991-
ISD::LLROUND, ISD::LRINT, ISD::LLRINT, ISD::FROUNDEVEN,
992-
ISD::FTAN},
990+
ISD::LLROUND, ISD::LRINT, ISD::LLRINT, ISD::FROUNDEVEN},
993991
{MVT::f32, MVT::f64, MVT::f128}, Expand);
994992

995993
// Default ISD::TRAP to expand (which turns it into abort).

llvm/lib/Target/DirectX/DXIL.td

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -266,9 +266,6 @@ def Cos : DXILOpMapping<12, unary, int_cos,
266266
def Sin : DXILOpMapping<13, unary, int_sin,
267267
"Returns sine(theta) for theta in radians.",
268268
[llvm_halforfloat_ty, LLVMMatchType<0>]>;
269-
def Tan : DXILOpMapping<14, unary, int_tan,
270-
"Returns tangent(theta) for theta in radians.",
271-
[llvm_halforfloat_ty, LLVMMatchType<0>]>;
272269
def Exp2 : DXILOpMapping<21, unary, int_exp2,
273270
"Returns the base 2 exponential, or 2**x, of the specified value."
274271
"exp2(x) = 2**x.",

0 commit comments

Comments
 (0)