Lines Matching defs:TargetLowering

1 //===-- TargetLowering.cpp - Implement the TargetLowering class -----------===//
9 // This implements the TargetLowering class.
13 #include "llvm/CodeGen/TargetLowering.h"
40 TargetLowering::TargetLowering(const TargetMachine &tm)
43 const char *TargetLowering::getTargetNodeName(unsigned Opcode) const {
47 bool TargetLowering::isPositionIndependent() const {
53 bool TargetLowering::isInTailCallPosition(SelectionDAG &DAG, SDNode *Node,
83 bool TargetLowering::parametersInCSRMatch(const MachineRegisterInfo &MRI,
147 TargetLowering::makeLibCall(SelectionDAG &DAG, RTLIB::Libcall LC, EVT RetVT,
155 TargetLowering::ArgListTy Args;
158 TargetLowering::ArgListEntry Entry;
180 TargetLowering::CallLoweringInfo CLI(DAG);
200 bool TargetLowering::findOptimalMemOpLowering(
292 void TargetLowering::softenSetCCOperands(SelectionDAG &DAG, EVT VT,
302 void TargetLowering::softenSetCCOperands(SelectionDAG &DAG, EVT VT,
407 TargetLowering::MakeLibCallOptions CallOptions;
444 unsigned TargetLowering::getJumpTableEncoding() const {
457 SDValue TargetLowering::getPICJumpTableRelocBase(SDValue Table,
472 TargetLowering::getPICJumpTableRelocBaseExpr(const MachineFunction *MF,
478 SDValue TargetLowering::expandIndirectJTBranch(const SDLoc &dl, SDValue Value,
490 TargetLowering::isOffsetFoldingLegal(const GlobalAddressSDNode *GA) const {
514 bool TargetLowering::ShrinkDemandedConstant(SDValue Op,
561 bool TargetLowering::ShrinkDemandedConstant(SDValue Op,
575 bool TargetLowering::ShrinkDemandedOp(SDValue Op, unsigned BitWidth,
625 bool TargetLowering::SimplifyDemandedBits(SDValue Op, const APInt &DemandedBits,
640 bool TargetLowering::SimplifyDemandedBits(SDValue Op, const APInt &DemandedBits,
657 bool TargetLowering::SimplifyDemandedBits(SDValue Op, const APInt &DemandedBits,
675 SDValue TargetLowering::SimplifyMultipleUseDemandedBits(
963 SDValue TargetLowering::SimplifyMultipleUseDemandedBits(
977 SDValue TargetLowering::SimplifyMultipleUseDemandedVectorElts(
988 TargetLowering::TargetLoweringOpt &TLO,
989 const TargetLowering &TLI,
1134 bool TargetLowering::SimplifyDemandedBits(
1752 TargetLowering::ZeroOrOneBooleanContent &&
3011 bool TargetLowering::SimplifyDemandedVectorElts(SDValue Op,
3077 bool TargetLowering::SimplifyDemandedVectorElts(
3774 void TargetLowering::computeKnownBitsForTargetNode(const SDValue Op,
3788 void TargetLowering::computeKnownBitsForTargetInstr(
3795 void TargetLowering::computeKnownBitsForFrameIndex(
3801 Align TargetLowering::computeKnownAlignForTargetInstr(
3809 unsigned TargetLowering::ComputeNumSignBitsForTargetNode(SDValue Op,
3822 unsigned TargetLowering::computeNumSignBitsForTargetInstr(
3828 bool TargetLowering::SimplifyDemandedVectorEltsForTargetNode(
3840 bool TargetLowering::SimplifyDemandedBitsForTargetNode(
3853 SDValue TargetLowering::SimplifyMultipleUseDemandedBitsForTargetNode(
3867 TargetLowering::buildLegalVectorShuffle(EVT VT, const SDLoc &DL, SDValue N0,
3883 const Constant *TargetLowering::getTargetConstantFromLoad(LoadSDNode*) const {
3887 bool TargetLowering::isGuaranteedNotToBeUndefOrPoisonForTargetNode(
3908 bool TargetLowering::canCreateUndefOrPoisonForTargetNode(
3921 bool TargetLowering::isKnownNeverNaNForTargetNode(SDValue Op,
3934 bool TargetLowering::isSplatValueForTargetNode(SDValue Op,
3951 bool TargetLowering::isConstTrueVal(SDValue N) const {
3981 bool TargetLowering::isConstFalseVal(SDValue N) const {
4005 bool TargetLowering::isExtendedTrueVal(const ConstantSDNode *N, EVT VT,
4010 TargetLowering::BooleanContent Cnt = getBooleanContents(VT);
4012 case TargetLowering::ZeroOrOneBooleanContent:
4016 case TargetLowering::UndefinedBooleanContent:
4017 case TargetLowering::ZeroOrNegativeOneBooleanContent:
4025 SDValue TargetLowering::foldSetCCWithAnd(EVT VT, SDValue N0, SDValue N1,
4040 (getBooleanContents(OpVT) == TargetLowering::UndefinedBooleanContent ||
4041 getBooleanContents(OpVT) == TargetLowering::ZeroOrOneBooleanContent)) {
4128 SDValue TargetLowering::optimizeSetCCOfSignedTruncationCheck(
4211 SDValue TargetLowering::optimizeSetCCByHoistingAndByConstFromLogicalShift(
4282 SDValue TargetLowering::foldSetCCWithBinOp(EVT VT, SDValue N0, SDValue N1,
4320 static SDValue simplifySetCCWithCTPOP(const TargetLowering &TLI, EVT VT,
4505 SDValue TargetLowering::SimplifySetCC(EVT VT, SDValue N0, SDValue N1,
5484 bool TargetLowering::isGAPlusOffset(SDNode *WN, const GlobalValue *&GA,
5514 SDValue TargetLowering::PerformDAGCombine(SDNode *N,
5524 TargetLowering::ConstraintType
5525 TargetLowering::getConstraintType(StringRef Constraint) const {
5571 const char *TargetLowering::LowerXConstraint(EVT ConstraintVT) const {
5579 SDValue TargetLowering::LowerAsmOutputForConstraint(
5587 void TargetLowering::LowerAsmOperandForConstraint(SDValue Op,
5664 void TargetLowering::CollectTargetIntrinsicOperands(
5669 TargetLowering::getRegForInlineAsmConstraint(const TargetRegisterInfo *RI,
5713 bool TargetLowering::AsmOperandInfo::isMatchingInputConstraint() const {
5720 unsigned TargetLowering::AsmOperandInfo::getMatchedOperand() const {
5730 TargetLowering::AsmOperandInfoVector
5731 TargetLowering::ParseConstraints(const DataLayout &DL,
5923 static unsigned getConstraintPiority(TargetLowering::ConstraintType CT) {
5925 case TargetLowering::C_Immediate:
5926 case TargetLowering::C_Other:
5928 case TargetLowering::C_Memory:
5929 case TargetLowering::C_Address:
5931 case TargetLowering::C_RegisterClass:
5933 case TargetLowering::C_Register:
5935 case TargetLowering::C_Unknown:
5944 TargetLowering::ConstraintWeight
5945 TargetLowering::getMultipleConstraintMatchWeight(
5968 TargetLowering::ConstraintWeight
5969 TargetLowering::getSingleConstraintMatchWeight(
6016 /// This is somewhat tricky: constraints (TargetLowering::ConstraintType) fall
6038 TargetLowering::ConstraintGroup TargetLowering::getConstraintPreferences(
6039 TargetLowering::AsmOperandInfo &OpInfo) const {
6044 TargetLowering::ConstraintType CType = getConstraintType(Code);
6047 if (OpInfo.isIndirect && !(CType == TargetLowering::C_Memory ||
6048 CType == TargetLowering::C_Register ||
6049 CType == TargetLowering::C_RegisterClass))
6054 if (CType == TargetLowering::C_Memory && OpInfo.hasMatchingInput())
6070 static bool lowerImmediateIfPossible(TargetLowering::ConstraintPair &P,
6072 const TargetLowering &TLI) {
6074 assert((P.second == TargetLowering::C_Other ||
6075 P.second == TargetLowering::C_Immediate) &&
6088 void TargetLowering::ComputeConstraintToUse(AsmOperandInfo &OpInfo,
6104 BestIdx < E && (G[BestIdx].second == TargetLowering::C_Other ||
6105 G[BestIdx].second == TargetLowering::C_Immediate);
6147 static SDValue BuildExactSDIV(const TargetLowering &TLI, SDNode *N,
6207 static SDValue BuildExactUDIV(const TargetLowering &TLI, SDNode *N,
6265 SDValue TargetLowering::BuildSDIVPow2(SDNode *N, const APInt &Divisor,
6275 TargetLowering::BuildSREMPow2(SDNode *N, const APInt &Divisor,
6292 SDValue TargetLowering::buildSDIVPow2WithCMov(
6331 SDValue TargetLowering::BuildSDIV(SDNode *N, SelectionDAG &DAG,
6499 SDValue TargetLowering::BuildUDIV(SDNode *N, SelectionDAG &DAG,
6728 SDValue TargetLowering::buildUREMEqFold(EVT SETCCVT, SDValue REMNode,
6745 TargetLowering::prepareUREMEqFold(EVT SETCCVT, SDValue REMNode,
6970 SDValue TargetLowering::buildSREMEqFold(EVT SETCCVT, SDValue REMNode,
6988 TargetLowering::prepareSREMEqFold(EVT SETCCVT, SDValue REMNode,
7259 bool TargetLowering::
7270 SDValue TargetLowering::getSqrtInputTest(SDValue Op, SelectionDAG &DAG,
7295 SDValue TargetLowering::getNegatedExpression(SDValue Op, SelectionDAG &DAG,
7603 bool TargetLowering::expandMUL_LOHI(unsigned Opcode, EVT VT, const SDLoc &dl,
7778 bool TargetLowering::expandMUL(SDNode *N, SDValue &Lo, SDValue &Hi, EVT HiLoVT,
7815 bool TargetLowering::expandDIVREMByConstant(SDNode *N,
8034 SDValue TargetLowering::expandFunnelShift(SDNode *Node,
8123 SDValue TargetLowering::expandROT(SDNode *Node, bool AllowVectorOps,
8178 void TargetLowering::expandShiftParts(SDNode *Node, SDValue &Lo, SDValue &Hi,
8230 bool TargetLowering::expandFP_TO_SINT(SDNode *Node, SDValue &Result,
8301 bool TargetLowering::expandFP_TO_UINT(SDNode *Node, SDValue &Result,
8403 bool TargetLowering::expandUINT_TO_FP(SDNode *Node, SDValue &Result,
8463 TargetLowering::createSelectForFMINNUM_FMAXNUM(SDNode *Node,
8489 SDValue TargetLowering::expandFMINNUM_FMAXNUM(SDNode *Node,
8545 SDValue TargetLowering::expandFMINIMUM_FMAXIMUM(SDNode *N,
8612 SDValue TargetLowering::expandFMINIMUMNUM_FMAXIMUMNUM(SDNode *Node,
8724 SDValue TargetLowering::expandIS_FPCLASS(EVT ResultVT, SDValue Op,
9073 static bool canExpandVectorCTPOP(const TargetLowering &TLI, EVT VT) {
9083 SDValue TargetLowering::expandCTPOP(SDNode *Node, SelectionDAG &DAG) const {
9160 SDValue TargetLowering::expandVPCTPOP(SDNode *Node, SelectionDAG &DAG) const {
9229 SDValue TargetLowering::expandCTLZ(SDNode *Node, SelectionDAG &DAG) const {
9279 SDValue TargetLowering::expandVPCTLZ(SDNode *Node, SelectionDAG &DAG) const {
9306 SDValue TargetLowering::CTTZTableLookup(SDNode *Node, SelectionDAG &DAG,
9350 SDValue TargetLowering::expandCTTZ(SDNode *Node, SelectionDAG &DAG) const {
9406 SDValue TargetLowering::expandVPCTTZ(SDNode *Node, SelectionDAG &DAG) const {
9422 SDValue TargetLowering::expandVPCTTZElements(SDNode *N,
9455 SDValue TargetLowering::expandVectorFindLastActive(SDNode *N,
9466 const TargetLowering &TLI = DAG.getTargetLoweringInfo();
9478 TargetLowering::TypePromoteInteger) {
9492 SDValue TargetLowering::expandABS(SDNode *N, SelectionDAG &DAG,
9547 SDValue TargetLowering::expandABD(SDNode *N, SelectionDAG &DAG) const {
9621 SDValue TargetLowering::expandAVG(SDNode *N, SelectionDAG &DAG) const {
9703 SDValue TargetLowering::expandBSWAP(SDNode *N, SelectionDAG &DAG) const {
9761 SDValue TargetLowering::expandVPBSWAP(SDNode *N, SelectionDAG &DAG) const {
9837 SDValue TargetLowering::expandBITREVERSE(SDNode *N, SelectionDAG &DAG) const {
9898 SDValue TargetLowering::expandVPBITREVERSE(SDNode *N, SelectionDAG &DAG) const {
9961 TargetLowering::scalarizeVectorLoad(LoadSDNode *LD,
10050 SDValue TargetLowering::scalarizeVectorStore(StoreSDNode *ST,
10128 TargetLowering::expandUnalignedLoad(LoadSDNode *LD, SelectionDAG &DAG) const {
10277 SDValue TargetLowering::expandUnalignedStore(StoreSDNode *ST,
10411 TargetLowering::IncrementMemoryAddress(SDValue Addr, SDValue Mask,
10483 SDValue TargetLowering::getVectorElementPointer(SelectionDAG &DAG,
10492 SDValue TargetLowering::getVectorSubVecPointer(SelectionDAG &DAG,
10526 SDValue TargetLowering::LowerToTLSEmulatedModel(const GlobalAddressSDNode *GA,
10550 TargetLowering::CallLoweringInfo CLI(DAG);
10566 SDValue TargetLowering::lowerCmpEqZeroToCtlzSrl(SDValue Op,
10589 SDValue TargetLowering::expandIntMINMAX(SDNode *Node, SelectionDAG &DAG) const {
10670 SDValue TargetLowering::expandAddSubSat(SDNode *Node, SelectionDAG &DAG) const {
10786 SDValue TargetLowering::expandCMP(SDNode *Node, SelectionDAG &DAG) const {
10821 SDValue TargetLowering::expandShlSat(SDNode *Node, SelectionDAG &DAG) const {
10860 void TargetLowering::forceExpandMultiply(SelectionDAG &DAG, const SDLoc &dl,
10918 void TargetLowering::forceExpandWideMUL(SelectionDAG &DAG, const SDLoc &dl,
10957 TargetLowering::MakeLibCallOptions CallOptions;
10984 TargetLowering::expandFixedPointMul(SDNode *Node, SelectionDAG &DAG) const {
11141 TargetLowering::expandFixedPointDiv(unsigned Opcode, const SDLoc &dl,
11226 void TargetLowering::expandUADDSUBO(
11272 void TargetLowering::expandSADDSUBO(
11312 bool TargetLowering::expandMULO(SDNode *Node, SDValue &Result,
11392 SDValue TargetLowering::expandVecReduce(SDNode *Node, SelectionDAG &DAG) const {
11432 SDValue TargetLowering::expandVecReduceSeq(SDNode *Node, SelectionDAG &DAG) const {
11459 bool TargetLowering::expandREM(SDNode *Node, SDValue &Result,
11483 SDValue TargetLowering::expandFP_TO_INT_SAT(SDNode *Node,
11593 SDValue TargetLowering::expandRoundInexactToOdd(EVT ResultVT, SDValue Op,
11661 SDValue TargetLowering::expandFP_ROUND(SDNode *Node, SelectionDAG &DAG) const {
11715 SDValue TargetLowering::expandVectorSplice(SDNode *Node,
11789 SDValue TargetLowering::expandVECTOR_COMPRESS(SDNode *Node,
11893 bool TargetLowering::LegalizeSetCCCondCode(SelectionDAG &DAG, EVT VT,
11907 case TargetLowering::Legal:
11910 case TargetLowering::Expand: {
12086 SDValue TargetLowering::expandVectorNaryOpBySplitting(SDNode *Node,