Home
last modified time | relevance | path

Searched refs:InstCombinerImpl (Results 1 – 16 of 16) sorted by relevance

/freebsd/contrib/llvm-project/llvm/lib/Transforms/InstCombine/
H A DInstCombineLoadStoreAlloca.cpp197 static Instruction *simplifyAllocaArraySize(InstCombinerImpl &IC, in simplifyAllocaArraySize()
251 PointerReplacer(InstCombinerImpl &IC, Instruction &Root, unsigned SrcAS) in PointerReplacer()
277 InstCombinerImpl ⁣
461 Instruction *InstCombinerImpl::visitAllocaInst(AllocaInst &AI) { in visitAllocaInst()
562 LoadInst *InstCombinerImpl::combineLoadToNewType(LoadInst &LI, Type *NewTy, in combineLoadToNewType()
578 static StoreInst *combineStoreToNewValue(InstCombinerImpl &IC, StoreInst &SI, in combineStoreToNewValue()
648 static Instruction *combineLoadToOperationType(InstCombinerImpl &IC, in combineLoadToOperationType()
693 static Instruction *unpackLoadToAggregate(InstCombinerImpl &IC, LoadInst &LI) { in unpackLoadToAggregate()
890 static bool canReplaceGEPIdxWithZero(InstCombinerImpl &IC, in canReplaceGEPIdxWithZero()
965 static Instruction *replaceGEPIdxWithZero(InstCombinerImpl &IC, Value *Ptr, in replaceGEPIdxWithZero()
[all …]
H A DInstructionCombining.cpp193 Value *InstCombinerImpl::EmitGEPOffset(GEPOperator *GEP, bool RewriteGEP) { in EmitGEPOffset()
220 bool InstCombinerImpl::isDesirableIntType(unsigned BitWidth) const { in isDesirableIntType()
239 bool InstCombinerImpl::shouldChangeType(unsigned FromWidth, in shouldChangeType()
267 bool InstCombinerImpl::shouldChangeType(Type *From, Type *To) const { in shouldChangeType()
336 InstCombinerImpl &IC) { in simplifyAssocCastAssoc()
384 Value *InstCombinerImpl::simplifyIntToPtrRoundTripCast(Value *Val) { in simplifyIntToPtrRoundTripCast()
420 bool InstCombinerImpl::SimplifyAssociativeOrCommutative(BinaryOperator &I) { in SimplifyAssociativeOrCommutative()
771 Instruction *InstCombinerImpl::tryFoldInstWithCtpopWithNot(Instruction *I) { in tryFoldInstWithCtpopWithNot()
876 Instruction *InstCombinerImpl::foldBinOpShiftWithShift(BinaryOperator &I) { in foldBinOpShiftWithShift()
1023 InstCombinerImpl::foldBinOpOfSelectAndCastOfSelectCondition(BinaryOperator &I) { in foldBinOpOfSelectAndCastOfSelectCondition()
[all …]
H A DInstCombineCasts.cpp30 Value *InstCombinerImpl::EvaluateInDifferentType(Value *V, Type *Ty, in EvaluateInDifferentType()
126 InstCombinerImpl::isEliminableCastPair(const CastInst *CI1, in isEliminableCastPair()
154 Instruction *InstCombinerImpl::commonCastTransforms(CastInst &CI) { in commonCastTransforms()
267 static bool canEvaluateTruncated(Value *V, Type *Ty, InstCombinerImpl &IC, in canEvaluateTruncated()
402 InstCombinerImpl &IC) { in foldVecTruncToExtElt()
441 Instruction *InstCombinerImpl::narrowFunnelShift(TruncInst &Trunc) { in narrowFunnelShift()
544 Instruction *InstCombinerImpl::narrowBinOp(TruncInst &Trunc) { in narrowBinOp()
677 Instruction *InstCombinerImpl::visitTrunc(TruncInst &Trunc) { in visitTrunc()
924 Instruction *InstCombinerImpl::transformZExtICmp(ICmpInst *Cmp, in transformZExtICmp()
1026 InstCombinerImpl &IC, Instruction *CxtI) { in canEvaluateZExtd()
[all …]
H A DInstCombinePHI.cpp43 void InstCombinerImpl::PHIArgMergedDebugLoc(Instruction *Inst, PHINode &PN) { in PHIArgMergedDebugLoc()
106 bool InstCombinerImpl::foldIntegerTypedPHI(PHINode &PN) { in foldIntegerTypedPHI()
307 Instruction *InstCombinerImpl::foldPHIArgIntToPtrToPHI(PHINode &PN) { in foldPHIArgIntToPtrToPHI()
331 InstCombinerImpl::foldPHIArgInsertValueInstructionIntoPHI(PHINode &PN) { in foldPHIArgInsertValueInstructionIntoPHI()
371 InstCombinerImpl::foldPHIArgExtractValueInstructionIntoPHI(PHINode &PN) { in foldPHIArgExtractValueInstructionIntoPHI()
407 Instruction *InstCombinerImpl::foldPHIArgBinOpIntoPHI(PHINode &PN) { in foldPHIArgBinOpIntoPHI()
502 Instruction *InstCombinerImpl::foldPHIArgGEPIntoPHI(PHINode &PN) { in foldPHIArgGEPIntoPHI()
665 Instruction *InstCombinerImpl::foldPHIArgLoadIntoPHI(PHINode &PN) { in foldPHIArgLoadIntoPHI()
789 Instruction *InstCombinerImpl::foldPHIArgZextsIntoPHI(PHINode &Phi) { in foldPHIArgZextsIntoPHI()
863 Instruction *InstCombinerImpl::foldPHIArgOpIntoPHI(PHINode &PN) { in foldPHIArgOpIntoPHI()
[all …]
H A DInstCombineCompares.cpp111 Instruction *InstCombinerImpl::foldCmpLoadFromIndexedGlobal( in foldCmpLoadFromIndexedGlobal()
674 Instruction *InstCombinerImpl::foldGEPICmp(GEPOperator *GEPLHS, Value *RHS, in foldGEPICmp()
834 bool InstCombinerImpl::foldAllocaCmp(AllocaInst *Alloca) { in foldAllocaCmp()
912 Instruction *InstCombinerImpl::foldICmpAddOpConst(Value *X, const APInt &C, in foldICmpAddOpConst()
962 Instruction *InstCombinerImpl::foldICmpShrConstConst(ICmpInst &I, Value *A, in foldICmpShrConstConst()
1021 Instruction *InstCombinerImpl::foldICmpShlConstConst(ICmpInst &I, Value *A, in foldICmpShlConstConst()
1067 InstCombinerImpl &IC) { in processUGT_ADDCST_ADD()
1152 Instruction *InstCombinerImpl::foldIRemByPowerOfTwoToBitTest(ICmpInst &I) { in foldIRemByPowerOfTwoToBitTest()
1171 Instruction *InstCombinerImpl::foldSignBitTest(ICmpInst &I) { in foldSignBitTest()
1202 Instruction *InstCombinerImpl::foldICmpWithZero(ICmpInst &Cmp) { in foldICmpWithZero()
[all …]
H A DInstCombineMulDivRem.cpp46 static Value *simplifyValueKnownNonZero(Value *V, InstCombinerImpl &IC, in simplifyValueKnownNonZero()
195 Instruction *InstCombinerImpl::visitMul(BinaryOperator &I) { in visitMul()
571 Instruction *InstCombinerImpl::foldFPSignBitOps(BinaryOperator &I) { in foldFPSignBitOps()
604 Instruction *InstCombinerImpl::foldPowiReassoc(BinaryOperator &I) { in foldPowiReassoc()
605 auto createPowiExpr = [](BinaryOperator &I, InstCombinerImpl &IC, Value *X, in foldPowiReassoc()
675 Instruction *InstCombinerImpl::foldFMulReassoc(BinaryOperator &I) { in foldFMulReassoc()
856 Instruction *InstCombinerImpl::visitFMul(BinaryOperator &I) { in visitFMul()
985 bool InstCombinerImpl::simplifyDivRemOfSelectWithZeroOp(BinaryOperator &I) { in simplifyDivRemOfSelectWithZeroOp()
1165 Instruction *InstCombinerImpl::commonIDivTransforms(BinaryOperator &I) { in commonIDivTransforms()
1473 InstCombinerImpl &IC) { in narrowUDivURem()
[all …]
H A DInstCombineShifts.cpp58 Value *InstCombinerImpl::reassociateShiftAmtsOfTwoSameDirectionShifts( in reassociateShiftAmtsOfTwoSameDirectionShifts()
405 Instruction *InstCombinerImpl::commonShiftTransforms(BinaryOperator &I) { in commonShiftTransforms()
521 InstCombinerImpl &IC, Instruction *CxtI) { in canEvaluateShiftedShift()
572 InstCombinerImpl &IC, Instruction *CxtI) { in canEvaluateShifted()
689 InstCombinerImpl &IC, const DataLayout &DL) { in getShiftedValue()
767 Instruction *InstCombinerImpl::FoldShiftByConstant(Value *Op0, Constant *C1, in FoldShiftByConstant()
906 Instruction *InstCombinerImpl::foldLShrOverflowBit(BinaryOperator &I) { in foldLShrOverflowBit()
1019 Instruction *InstCombinerImpl::visitShl(BinaryOperator &I) { in visitShl()
1256 Instruction *InstCombinerImpl::visitLShr(BinaryOperator &I) { in visitLShr()
1599 InstCombinerImpl::foldVariableSignZeroExtensionOfVariableHighBitExtract( in foldVariableSignZeroExtensionOfVariableHighBitExtract()
[all …]
H A DInstCombineAndOrXor.cpp52 Value *InstCombinerImpl::insertRangeTest(Value *V, const APInt &Lo, in insertRangeTest()
653 Value *InstCombinerImpl::simplifyRangeCheck(ICmpInst *Cmp0, ICmpInst *Cmp1, in simplifyRangeCheck()
745 Value *InstCombinerImpl::foldAndOrOfICmpsOfAndWithPow2(ICmpInst *LHS, in foldAndOrOfICmpsOfAndWithPow2()
933 InstCombinerImpl &IC) { in foldIsPowerOf2()
1148 Value *InstCombinerImpl::foldEqOfParts(ICmpInst *Cmp0, ICmpInst *Cmp1, in foldEqOfParts()
1269 Value *InstCombinerImpl::foldAndOrOfICmpsUsingRanges(ICmpInst *ICmp1, in foldAndOrOfICmpsUsingRanges()
1377 Value *InstCombinerImpl::foldLogicOfFCmps(FCmpInst *LHS, FCmpInst *RHS, in foldLogicOfFCmps()
1526 Instruction *InstCombinerImpl::foldLogicOfIsFPClass(BinaryOperator &BO, in foldLogicOfIsFPClass()
1592 Instruction *InstCombinerImpl::canonicalizeConditionalNegationViaMathToSelect( in canonicalizeConditionalNegationViaMathToSelect()
1691 bool InstCombinerImpl::shouldOptimizeCast(CastInst *CI) { in shouldOptimizeCast()
[all …]
H A DInstCombineSelect.cpp57 InstCombinerImpl &IC) { in foldSelectBinOpIdentity()
271 Instruction *InstCombinerImpl::foldSelectOpOp(SelectInst &SI, Instruction *TI, in foldSelectOpOp()
510 Instruction *InstCombinerImpl::foldSelectIntoOp(SelectInst &SI, Value *TrueVal, in foldSelectIntoOp()
858 static Instruction *foldSelectZeroOrMul(SelectInst &SI, InstCombinerImpl &IC) { in foldSelectZeroOrMul()
1135 InstCombinerImpl &IC) { in foldSelectCttzCtlz()
1194 InstCombinerImpl &IC) { in canonicalizeSPF()
1244 bool InstCombinerImpl::replaceInInstruction(Value *V, Value *Old, Value *New, in replaceInInstruction()
1286 Instruction *InstCombinerImpl::foldSelectValueEquivalence(SelectInst &Sel, in foldSelectValueEquivalence()
1573 InstCombinerImpl &IC) { in tryToReuseConstantFromSelectInComparison()
1718 InstCombinerImpl &IC) { in foldSelectICmpEq()
[all …]
H A DInstCombineCalls.cpp115 Instruction *InstCombinerImpl::SimplifyAnyMemTransfer(AnyMemTransferInst *MI) { in SimplifyAnyMemTransfer()
217 Instruction *InstCombinerImpl::SimplifyAnyMemSet(AnyMemSetInst *MI) { in SimplifyAnyMemSet()
293 Value *InstCombinerImpl::simplifyMaskedLoad(IntrinsicInst &II) { in simplifyMaskedLoad()
323 Instruction *InstCombinerImpl::simplifyMaskedStore(IntrinsicInst &II) { in simplifyMaskedStore()
361 Instruction *InstCombinerImpl::simplifyMaskedGather(IntrinsicInst &II) { in simplifyMaskedGather()
389 Instruction *InstCombinerImpl::simplifyMaskedScatter(IntrinsicInst &II) { in simplifyMaskedScatter()
452 InstCombinerImpl &IC) { in simplifyInvariantGroupIntrinsic()
481 static Instruction *foldCttzCtlz(IntrinsicInst &II, InstCombinerImpl &IC) { in foldCttzCtlz()
629 static Instruction *foldCtpop(IntrinsicInst &II, InstCombinerImpl &IC) { in foldCtpop()
766 removeTriviallyEmptyRange(IntrinsicInst &EndI, InstCombinerImpl &IC, in removeTriviallyEmptyRange()
[all …]
H A DInstCombineInternal.h62 class LLVM_LIBRARY_VISIBILITY InstCombinerImpl final
64 public InstVisitor<InstCombinerImpl, Instruction *> {
66 InstCombinerImpl(InstructionWorklist &Worklist, BuilderTy &Builder, in InstCombinerImpl() function
75 virtual ~InstCombinerImpl() = default;
818 InstCombinerImpl &IC);
H A DInstCombineAtomicRMW.cpp103 Instruction *InstCombinerImpl::visitAtomicRMWInst(AtomicRMWInst &RMWI) { in visitAtomicRMWInst()
H A DInstCombineSimplifyDemanded.cpp68 bool InstCombinerImpl::SimplifyDemandedInstructionBits(Instruction &Inst, in SimplifyDemandedInstructionBits()
81 bool InstCombinerImpl::SimplifyDemandedInstructionBits(Instruction &Inst) { in SimplifyDemandedInstructionBits()
89 bool InstCombinerImpl::SimplifyDemandedBits(Instruction *I, unsigned OpNo, in SimplifyDemandedBits()
157 Value *InstCombinerImpl::SimplifyDemandedUseBits(Instruction *I, in SimplifyDemandedUseBits()
1140 Value *InstCombinerImpl::SimplifyMultipleUseDemandedBits( in SimplifyMultipleUseDemandedBits()
1318 Value *InstCombinerImpl::simplifyShrShlDemandedBits( in simplifyShrShlDemandedBits()
1393 Value *InstCombinerImpl::SimplifyDemandedVectorElts(Value *V, in SimplifyDemandedVectorElts()
1958 Value *InstCombinerImpl::SimplifyDemandedUseFPClass( in SimplifyDemandedUseFPClass()
2059 bool InstCombinerImpl::SimplifyDemandedFPClass(Instruction *I, unsigned OpNo, in SimplifyDemandedFPClass()
H A DInstCombineVectorOps.cpp100 Instruction *InstCombinerImpl::scalarizePHI(ExtractElementInst &EI, in scalarizePHI()
183 Instruction *InstCombinerImpl::foldBitcastExtElt(ExtractElementInst &Ext) { in foldBitcastExtElt()
398 Instruction *InstCombinerImpl::visitExtractElementInst(ExtractElementInst &EI) { in visitExtractElementInst()
696 InstCombinerImpl &IC) { in replaceExtractElements()
783 InstCombinerImpl &IC, bool &Rerun) { in collectShuffleElements()
868 Instruction *InstCombinerImpl::foldAggregateConstructionIntoAggregateReuse( in foldAggregateConstructionIntoAggregateReuse()
1148 Instruction *InstCombinerImpl::visitInsertValueInst(InsertValueInst &I) { in visitInsertValueInst()
1606 Instruction *InstCombinerImpl::visitInsertElementInst(InsertElementInst &IE) { in visitInsertElementInst()
2247 Instruction *InstCombinerImpl::foldSelectShuffle(ShuffleVectorInst &Shuf) { in foldSelectShuffle()
2608 InstCombinerImpl &IC) { in foldShuffleWithInsert()
[all …]
H A DInstCombineAddSub.cpp856 Instruction *InstCombinerImpl::foldAddWithConstant(BinaryOperator &Add) { in foldAddWithConstant()
1052 Instruction *InstCombinerImpl::foldSquareSumInt(BinaryOperator &I) { in foldSquareSumInt()
1063 Instruction *InstCombinerImpl::foldSquareSumFP(BinaryOperator &I) { in foldSquareSumFP()
1150 Value *InstCombinerImpl::SimplifyAddWithRemainder(BinaryOperator &I) { in SimplifyAddWithRemainder()
1307 Instruction *InstCombinerImpl::
1486 Instruction *InstCombinerImpl::visitAdd(BinaryOperator &I) { in visitAdd()
1887 Instruction *InstCombinerImpl::visitFAdd(BinaryOperator &I) { in visitFAdd()
2003 Value *InstCombinerImpl::OptimizePointerDifference(Value *LHS, Value *RHS, in OptimizePointerDifference()
2112 Instruction *InstCombinerImpl::visitSub(BinaryOperator &I) { in visitSub()
2714 Instruction *InstCombinerImpl::hoistFNegAboveFMulFDiv(Value *FNegOp, in hoistFNegAboveFMulFDiv()
[all …]
H A DInstCombineNegator.cpp547 InstCombinerImpl &IC) { in Negate()