/freebsd/contrib/llvm-project/llvm/include/llvm/CodeGen/GlobalISel/ |
H A D | MIPatternMatch.h | 554 SrcTy L; 569 template <typename SrcTy> 576 inline UnaryOp_match<SrcTy, TargetOpcode::G_SEXT> m_GSExt(const SrcTy &Src) { 581 inline UnaryOp_match<SrcTy, TargetOpcode::G_ZEXT> m_GZExt(const SrcTy &Src) { 586 inline UnaryOp_match<SrcTy, TargetOpcode::G_FPEXT> m_GFPExt(const SrcTy &Src) { 591 inline UnaryOp_match<SrcTy, TargetOpcode::G_TRUNC> m_GTrunc(const SrcTy &Src) { 620 inline UnaryOp_match<SrcTy, TargetOpcode::G_FABS> m_GFabs(const SrcTy &Src) { 625 inline UnaryOp_match<SrcTy, TargetOpcode::G_FNEG> m_GFNeg(const SrcTy &Src) { 630 inline UnaryOp_match<SrcTy, TargetOpcode::COPY> m_Copy(SrcTy &&Src) { 631 return UnaryOp_match<SrcTy, TargetOpcode::COPY>(std::forward<SrcTy>(Src)); [all …]
|
H A D | LegalizationArtifactCombiner.h | 134 LLT SrcTy = MRI.getType(SrcReg); in tryCombineZExt() local 135 APInt MaskVal = APInt::getAllOnes(SrcTy.getScalarSizeInBits()); in tryCombineZExt() 204 LLT SrcTy = MRI.getType(SrcReg); in tryCombineSExt() local 205 uint64_t SizeInBits = SrcTy.getScalarSizeInBits(); in tryCombineSExt() 415 const LLT SrcTy = MRI.getType(MI.getOperand(NumDefs).getReg()); in tryFoldUnmergeCast() local 421 if (SrcTy.isVector() && SrcTy.getScalarType() == DestTy.getScalarType()) { in tryFoldUnmergeCast() 453 if (CastSrcTy.isScalar() && SrcTy.isScalar() && !DestTy.isVector()) { in tryFoldUnmergeCast() 661 LLT SrcTy = MRI.getType(Src1Reg); in findValueFromBuildVector() local 662 LLT NewBVTy = LLT::fixed_vector(NumSrcsUsed, SrcTy); in findValueFromBuildVector() 1258 LLT SrcTy = MRI.getType(SrcReg); in tryCombineExtract() local [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Transforms/InstCombine/ |
H A D | InstCombineCasts.cpp | 128 Type *SrcTy = CI1->getSrcTy(); in isEliminableCastPair() local 135 SrcTy->isPtrOrPtrVectorTy() ? DL.getIntPtrType(SrcTy) : nullptr; in isEliminableCastPair() 212 if (SrcTy && DestTy && in commonCastTransforms() 537 Type *SrcTy = Trunc.getSrcTy(); in narrowBinOp() local 542 if (!isa<VectorType>(SrcTy) && !shouldChangeType(SrcTy, DestTy)) in narrowBinOp() 811 (isa<VectorType>(SrcTy) || shouldChangeType(SrcTy, DestTy))) { in visitTrunc() 1627 Type *SrcTy = Src->getType(); in isKnownExactCastIntToFP() local 1957 Type *SrcTy = SrcOp->getType(); in visitPtrToInt() local 2038 SrcTy = in optimizeVectorResizeWithIntegerBitCasts() 2062 V2 = PoisonValue::get(SrcTy); in optimizeVectorResizeWithIntegerBitCasts() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/AArch64/GISel/ |
H A D | AArch64RegisterBankInfo.cpp | 693 LLT SrcTy = MRI.getType(MI.getOperand(1).getReg()); in getInstrMapping() local 704 LLT SrcTy = MRI.getType(MI.getOperand(1).getReg()); in getInstrMapping() local 737 LLT SrcTy = MRI.getType(MI.getOperand(1).getReg()); in getInstrMapping() local 740 bool SrcIsGPR = !SrcTy.isVector() && SrcTy.getSizeInBits() <= 64; in getInstrMapping() 800 LLT SrcTy = MRI.getType(MI.getOperand(1).getReg()); in getInstrMapping() local 801 if (!SrcTy.isVector() && SrcTy.getSizeInBits() == 128) in getInstrMapping() 924 if (SrcTy.isVector()) { in getInstrMapping() 981 if (SrcTy.isVector() || SrcTy == LLT::scalar(128) || in getInstrMapping() 1016 if (SrcTy.getSizeInBits() != 128) in getInstrMapping() 1041 const LLT SrcTy = MRI.getType(VReg); in getInstrMapping() local [all …]
|
H A D | AArch64PreLegalizerCombiner.cpp | 250 LLT SrcTy; in matchExtAddvToUdotAddv() local 284 if (SrcTy.getScalarSizeInBits() != 8 || SrcTy.getNumElements() % 8 != 0) in matchExtAddvToUdotAddv() 315 LLT SrcTy = MRI.getType(Ext1SrcReg); in applyExtAddvToUdotAddv() local 318 if (SrcTy.getNumElements() % 16 == 0) { in applyExtAddvToUdotAddv() 319 NumOfDotMI = SrcTy.getNumElements() / 16; in applyExtAddvToUdotAddv() 321 } else if (SrcTy.getNumElements() % 8 == 0) { in applyExtAddvToUdotAddv() 322 NumOfDotMI = SrcTy.getNumElements() / 8; in applyExtAddvToUdotAddv() 338 if (SrcTy.getNumElements() % 16 != 0) { in applyExtAddvToUdotAddv() 456 LLT SrcTy = MRI.getType(SrcReg); in applyExtUaddvToUaddlv() local 464 unsigned SrcNumElem = SrcTy.getNumElements(); in applyExtUaddvToUaddlv() [all …]
|
H A D | AArch64PostLegalizerLowering.cpp | 698 const LLT SrcTy = MRI.getType(Src1Reg); in matchDupLane() local 706 if (*LaneIdx >= SrcTy.getNumElements()) in matchDupLane() 709 if (DstTy != SrcTy) in matchDupLane() 712 LLT ScalarTy = SrcTy.getElementType(); in matchDupLane() 716 switch (SrcTy.getNumElements()) { in matchDupLane() 754 const LLT SrcTy = MRI.getType(Src1Reg); in applyDupLane() local 762 if (SrcTy.getSizeInBits() == 64) { in applyDupLane() 763 auto Undef = B.buildUndef(SrcTy); in applyDupLane() 775 const LLT SrcTy = MRI.getType(Src1Reg); in matchScalarizeVectorUnmerge() local 776 return SrcTy.isVector() && !SrcTy.isScalable() && in matchScalarizeVectorUnmerge() [all …]
|
H A D | AArch64LegalizerInfo.cpp | 152 const auto &SrcTy = Query.Types[0]; in AArch64LegalizerInfo() local 154 return !SrcTy.isVector() && SrcTy.getSizeInBits() == 32 && in AArch64LegalizerInfo() 519 const LLT &SrcTy = Query.Types[1]; in AArch64LegalizerInfo() local 585 const LLT &SrcTy = Query.Types[1]; in AArch64LegalizerInfo() local 590 unsigned SrcSize = SrcTy.getSizeInBits(); in AArch64LegalizerInfo() 624 LLT SrcTy = Query.Types[1]; in AArch64LegalizerInfo() local 932 const LLT &SrcTy = Query.Types[1]; in AArch64LegalizerInfo() local 935 if (DstTy != SrcTy) in AArch64LegalizerInfo() 1094 LLT SrcTy = Q.Types[1]; in AArch64LegalizerInfo() local 1095 if (SrcTy.isScalar()) in AArch64LegalizerInfo() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/GlobalISel/ |
H A D | LegalizerHelper.cpp | 238 if (SrcTy == GCDTy) { in extractGCDType() 1927 SrcTy = LLT::scalar(SrcTy.getSizeInBits()); in widenScalarUnmergeValues() 5940 if (SrcTy.isScalar() && SrcTy.getSizeInBits() == 2 * NarrowSize) { in narrowScalarCTLZ() 5973 if (SrcTy.isScalar() && SrcTy.getSizeInBits() == 2 * NarrowSize) { in narrowScalarCTTZ() 6006 if (SrcTy.isScalar() && SrcTy.getSizeInBits() == 2 * NarrowSize) { in narrowScalarCTPOP() 6094 SrcTy, Op, MIRBuilder.buildLShr(SrcTy, Op, MIBShiftAmt)); in lowerBitCount() 6134 if (!isSupported({TargetOpcode::G_CTPOP, {SrcTy, SrcTy}}) && in lowerBitCount() 6135 isSupported({TargetOpcode::G_CTLZ, {SrcTy, SrcTy}})) { in lowerBitCount() 6611 if (SrcTy != S64) in lowerSITOFP() 6644 if (SrcTy != S64 && SrcTy != S32) in lowerFPTOUI() [all …]
|
H A D | CallLowering.cpp | 534 if (PartTy.isVector() == SrcTy.isVector() && in buildCopyToRegs() 541 if (SrcTy.isVector() && !PartTy.isVector() && in buildCopyToRegs() 550 if (SrcTy.isVector() && PartTy.isVector() && in buildCopyToRegs() 559 LLT GCDTy = getGCDType(SrcTy, PartTy); in buildCopyToRegs() 568 LLT LCMTy = getCoverTy(SrcTy, PartTy); in buildCopyToRegs() 577 const unsigned SrcSize = SrcTy.getSizeInBits(); in buildCopyToRegs() 584 if (SrcTy.isScalar() && DstTy.isScalar()) { in buildCopyToRegs() 1255 if (SrcTy == DstTy) in isCopyCompatibleType() 1261 SrcTy = SrcTy.getScalarType(); in isCopyCompatibleType() 1264 return (SrcTy.isPointer() && DstTy.isScalar()) || in isCopyCompatibleType() [all …]
|
H A D | GISelKnownBits.cpp | 458 LLT SrcTy = MRI.getType(SrcReg); in computeKnownBitsImpl() local 465 SrcBitWidth = SrcTy.isPointer() in computeKnownBitsImpl() 466 ? DL.getIndexSizeInBits(SrcTy.getAddressSpace()) in computeKnownBitsImpl() 467 : SrcTy.getSizeInBits(); in computeKnownBitsImpl() 650 LLT SrcTy = MRI.getType(Src); in computeNumSignBits() local 651 unsigned Tmp = DstTy.getScalarSizeInBits() - SrcTy.getScalarSizeInBits(); in computeNumSignBits() 682 LLT SrcTy = MRI.getType(Src); in computeNumSignBits() local 686 unsigned NumSrcBits = SrcTy.getScalarSizeInBits(); in computeNumSignBits()
|
H A D | MachineIRBuilder.cpp | 576 LLT SrcTy = Src.getLLTTy(*getMRI()); in buildCast() local 578 if (SrcTy == DstTy) in buildCast() 582 if (SrcTy.isPointer() && DstTy.isScalar()) in buildCast() 584 else if (DstTy.isPointer() && SrcTy.isScalar()) in buildCast() 587 assert(!SrcTy.isPointer() && !DstTy.isPointer() && "n G_ADDRCAST yet"); in buildCast() 597 LLT SrcTy = Src.getLLTTy(*getMRI()); in buildExtract() local 601 assert(SrcTy.isValid() && "invalid operand type"); in buildExtract() 603 assert(Index + DstTy.getSizeInBits() <= SrcTy.getSizeInBits() && in buildExtract() 607 if (DstTy.getSizeInBits() == SrcTy.getSizeInBits()) { in buildExtract() 1081 void MachineIRBuilder::validateTruncExt(const LLT DstTy, const LLT SrcTy, in validateTruncExt() argument [all …]
|
H A D | CSEMIRBuilder.cpp | 198 LLT SrcTy = SrcOps[0].getLLTTy(*getMRI()); in buildInstr() local 201 getDataLayout().isNonIntegralAddressSpace(SrcTy.getAddressSpace())) in buildInstr() 204 if (SrcTy.isVector()) { in buildInstr()
|
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/ |
H A D | MachineVerifier.cpp | 1111 LLT SrcTy = MRI->getType(Src); in verifyPreISelGenericInstruction() local 1245 if (SrcTy == DstTy) in verifyPreISelGenericInstruction() 1261 SrcTy = SrcTy.getScalarType(); in verifyPreISelGenericInstruction() 1266 if (SrcTy.isPointer()) in verifyPreISelGenericInstruction() 1269 if (!SrcTy.isPointer()) in verifyPreISelGenericInstruction() 1335 LLT SrcElTy = SrcTy.getScalarType(); in verifyPreISelGenericInstruction() 1402 if (!SrcTy.isVector() || SrcTy.getScalarType() != DstTy.getScalarType() || in verifyPreISelGenericInstruction() 1407 } else if (SrcTy.isVector()) { in verifyPreISelGenericInstruction() 1796 LLT SrcEltTy = SrcTy.getScalarType(); in verifyPreISelGenericInstruction() 1947 LLT SrcTy = MRI->getType(SrcReg); in visitMachineInstrBefore() local [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Linker/ |
H A D | IRMover.cpp | 67 void addTypeMapping(Type *DstTy, Type *SrcTy); 75 Type *get(Type *SrcTy); 85 Type *remapType(Type *SrcTy) override { return get(SrcTy); } in remapType() argument 97 if (!areTypesIsomorphic(DstTy, SrcTy)) { in addTypeMapping() 127 if (DstTy->getTypeID() != SrcTy->getTypeID()) in areTypesIsomorphic() 131 Type *&Entry = MappedTypes[SrcTy]; in areTypesIsomorphic() 137 if (DstTy == SrcTy) { in areTypesIsomorphic() 149 SpeculativeTypes.push_back(SrcTy); in areTypesIsomorphic() 162 SpeculativeTypes.push_back(SrcTy); in areTypesIsomorphic() 183 StructType *SSTy = cast<StructType>(SrcTy); in areTypesIsomorphic() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/IR/ |
H A D | Instructions.cpp | 3213 if (SrcTy->isIntegerTy()) in isEliminableCastPair() 3219 if (SrcTy->isFloatingPointTy()) in isEliminableCastPair() 3253 if (SrcTy == DstTy) in isEliminableCastPair() 3557 if (SrcTy == DestTy) in isBitCastable() 3617 Type *SrcTy = Src->getType(); in getCastOpcode() local 3622 if (SrcTy == DestTy) in getCastOpcode() 3657 } else if (SrcTy->isVectorTy()) { in getCastOpcode() 3662 assert(SrcTy->isPointerTy() && in getCastOpcode() 3680 } else if (SrcTy->isVectorTy()) { in getCastOpcode() 3691 if (SrcTy->isPointerTy()) { in getCastOpcode() [all …]
|
H A D | Verifier.cpp | 3081 Type *SrcTy = I.getOperand(0)->getType(); in visitTruncInst() local 3173 bool SrcVec = SrcTy->isVectorTy(); in visitUIToFPInst() 3178 Check(SrcTy->isIntOrIntVectorTy(), in visitUIToFPInst() 3196 bool SrcVec = SrcTy->isVectorTy(); in visitSIToFPInst() 3201 Check(SrcTy->isIntOrIntVectorTy(), in visitSIToFPInst() 3219 bool SrcVec = SrcTy->isVectorTy(); in visitFPToUIInst() 3241 bool SrcVec = SrcTy->isVectorTy(); in visitFPToSIInst() 3269 if (SrcTy->isVectorTy()) { in visitPtrToIntInst() 3270 auto *VSrc = cast<VectorType>(SrcTy); in visitPtrToIntInst() 3289 if (SrcTy->isVectorTy()) { in visitIntToPtrInst() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/X86/GISel/ |
H A D | X86InstructionSelector.cpp | 766 const LLT SrcTy = MRI.getType(SrcReg); in selectTruncOrPtrToInt() local 830 const LLT SrcTy = MRI.getType(SrcReg); in selectZext() local 845 if (SrcTy != LLT::scalar(1)) in selectZext() 895 const LLT SrcTy = MRI.getType(SrcReg); in selectAnyext() local 1200 const LLT SrcTy = MRI.getType(SrcReg); in selectExtract() local 1251 const LLT SrcTy = MRI.getType(SrcReg); in emitExtractSubreg() local 1289 const LLT SrcTy = MRI.getType(SrcReg); in emitInsertSubreg() local 1299 if (SrcTy.getSizeInBits() == 128) in emitInsertSubreg() 1301 else if (SrcTy.getSizeInBits() == 256) in emitInsertSubreg() 1416 const LLT SrcTy = MRI.getType(SrcReg0); in selectMergeValues() local [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/ARM/ |
H A D | ARMTargetTransformInfo.cpp | 495 EVT SrcTy = TLI->getValueType(DL, Src); in getCastInstrCost() local 498 if (!SrcTy.isSimple() || !DstTy.isSimple()) in getCastInstrCost() 731 if (SrcTy.isVector() && ST->hasNEON()) { in getCastInstrCost() 792 if (SrcTy.isInteger() && ST->hasNEON()) { in getCastInstrCost() 831 if (SrcTy.isFixedLengthVector()) in getCastInstrCost() 832 Lanes = SrcTy.getVectorNumElements(); in getCastInstrCost() 841 SrcTy.isFixedLengthVector()) { in getCastInstrCost() 844 if ((SrcTy.getScalarType() == MVT::i8 || in getCastInstrCost() 845 SrcTy.getScalarType() == MVT::i16 || in getCastInstrCost() 847 SrcTy.getSizeInBits() > 128 && in getCastInstrCost() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/Hexagon/ |
H A D | HexagonTargetTransformInfo.cpp | 308 Type *SrcTy, in getCastInstrCost() argument 315 if (isNonHVXFP(SrcTy) || isNonHVXFP(DstTy)) in getCastInstrCost() 318 if (SrcTy->isFPOrFPVectorTy() || DstTy->isFPOrFPVectorTy()) { in getCastInstrCost() 319 unsigned SrcN = SrcTy->isFPOrFPVectorTy() ? getTypeNumElements(SrcTy) : 0; in getCastInstrCost() 322 std::pair<InstructionCost, MVT> SrcLT = getTypeLegalizationCost(SrcTy); in getCastInstrCost()
|
/freebsd/contrib/llvm-project/clang/lib/CodeGen/ |
H A D | CGExprScalar.cpp | 1256 SrcElementTy = SrcTy; in EmitScalarCast() 1374 SrcTy = CGF.FloatTy; in EmitScalarConversion() 1379 if (SrcTy == DstTy) { in EmitScalarConversion() 1523 if (SrcTy->isRealFloatingType()) in EmitFixedPointConversion() 1538 else if (SrcTy->isIntegerType()) in EmitFixedPointConversion() 1553 SrcTy = SrcTy->castAs<ComplexType>()->getElementType(); in EmitComplexToScalarConversion() 1722 if (SrcTy == DstTy) in VisitConvertVectorExpr() 1728 assert(SrcTy->isVectorTy() && in VisitConvertVectorExpr() 5073 auto SrcTy = Src->getType(); in createCastsForTypeOfSameSize() local 5093 if (!SrcTy->isIntegerTy()) in createCastsForTypeOfSameSize() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/SystemZ/ |
H A D | SystemZTargetTransformInfo.cpp | 657 getVectorTruncCost(Type *SrcTy, Type *DstTy) { in getVectorTruncCost() argument 658 assert (SrcTy->isVectorTy() && DstTy->isVectorTy()); in getVectorTruncCost() 659 assert(SrcTy->getPrimitiveSizeInBits().getFixedValue() > in getVectorTruncCost() 662 assert(cast<FixedVectorType>(SrcTy)->getNumElements() == in getVectorTruncCost() 668 unsigned NumParts = getNumVectorRegs(SrcTy); in getVectorTruncCost() 678 unsigned Log2Diff = getElSizeLog2Diff(SrcTy, DstTy); in getVectorTruncCost() 689 if (VF == 8 && SrcTy->getScalarSizeInBits() == 64 && in getVectorTruncCost() 700 assert (SrcTy->isVectorTy() && DstTy->isVectorTy() && in getVectorBitmaskConversionCost() 704 unsigned SrcScalarBits = SrcTy->getScalarSizeInBits(); in getVectorBitmaskConversionCost() 706 unsigned Log2Diff = getElSizeLog2Diff(SrcTy, DstTy); in getVectorBitmaskConversionCost() [all …]
|
H A D | SystemZTargetTransformInfo.h | 99 unsigned getVectorTruncCost(Type *SrcTy, Type *DstTy); 100 unsigned getVectorBitmaskConversionCost(Type *SrcTy, Type *DstTy);
|
/freebsd/contrib/llvm-project/llvm/lib/ExecutionEngine/Interpreter/ |
H A D | Execution.cpp | 1270 Type *SrcTy = SrcVal->getType(); in executeTruncInst() local 1271 if (SrcTy->isVectorTy()) { in executeTruncInst() 1291 if (SrcTy->isVectorTy()) { in executeSExtInst() 1311 if (SrcTy->isVectorTy()) { in executeZExtInst() 1378 if (isa<VectorType>(SrcTy)) { in executeFPToUIInst() 1416 if (isa<VectorType>(SrcTy)) { in executeFPToSIInst() 1557 if (isa<VectorType>(SrcTy)) { in executeBitCastInst() 1564 SrcElemTy = SrcTy; in executeBitCastInst() 1673 if (SrcTy->isFloatTy()) in executeBitCastInst() 1683 if (SrcTy->isIntegerTy()) in executeBitCastInst() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/AMDGPU/ |
H A D | AMDGPUPostLegalizerCombiner.cpp | 274 LLT SrcTy = MRI.getType(SrcReg); in applyUCharToFloat() local 275 if (SrcTy != S32) in applyUCharToFloat() 372 LLT SrcTy = MRI.getType(MatchInfo.CvtVal); in applyCvtF32UByteN() local 373 if (SrcTy != S32) { in applyCvtF32UByteN() 374 assert(SrcTy.isScalar() && SrcTy.getSizeInBits() >= 8); in applyCvtF32UByteN()
|
/freebsd/contrib/llvm-project/llvm/lib/Transforms/IPO/ |
H A D | MergeFunctions.cpp | 483 Type *SrcTy = V->getType(); in createCast() local 484 if (SrcTy->isStructTy()) { in createCast() 486 assert(SrcTy->getStructNumElements() == DestTy->getStructNumElements()); in createCast() 488 for (unsigned int I = 0, E = SrcTy->getStructNumElements(); I < E; ++I) { in createCast() 498 if (SrcTy->isIntegerTy() && DestTy->isPointerTy()) in createCast() 500 else if (SrcTy->isPointerTy() && DestTy->isIntegerTy()) in createCast()
|