Home
last modified time | relevance | path

Searched refs:SCEV (Results 1 – 25 of 85) sorted by relevance

1234

/freebsd-14.2/contrib/llvm-project/llvm/include/llvm/Analysis/
H A DScalarEvolution.h141 SCEV(const SCEV &) = delete;
584 const SCEV *getAddExpr(const SCEV *LHS, const SCEV *RHS,
590 const SCEV *getAddExpr(const SCEV *Op0, const SCEV *Op1, const SCEV *Op2,
599 const SCEV *getMulExpr(const SCEV *LHS, const SCEV *RHS,
605 const SCEV *getMulExpr(const SCEV *Op0, const SCEV *Op1, const SCEV *Op2,
611 const SCEV *getUDivExpr(const SCEV *LHS, const SCEV *RHS);
613 const SCEV *getURemExpr(const SCEV *LHS, const SCEV *RHS);
643 const SCEV *getSMaxExpr(const SCEV *LHS, const SCEV *RHS);
645 const SCEV *getUMaxExpr(const SCEV *LHS, const SCEV *RHS);
647 const SCEV *getSMinExpr(const SCEV *LHS, const SCEV *RHS);
[all …]
H A DDependenceAnalysis.h53 class SCEV; variable
409 const SCEV *A;
410 const SCEV *B;
411 const SCEV *C;
463 void setLine(const SCEV *A, const SCEV *B,
589 bool isKnownLessThan(const SCEV *S, const SCEV *Size) const;
813 const SCEV *getPositivePart(const SCEV *X) const;
817 const SCEV *getNegativePart(const SCEV *X) const;
924 const SCEV *findCoefficient(const SCEV *Expr,
932 const SCEV *zeroCoefficient(const SCEV *Expr,
[all …]
H A DScalarEvolutionExpressions.h80 class SCEVVScale : public SCEV {
105 const SCEV *Op;
202 const SCEV *const *Operands;
309 SCEVUDivExpr(const FoldingSetNodeIDRef ID, const SCEV *lhs, const SCEV *rhs) in SCEVUDivExpr()
397 const SCEV *evaluateAtIteration(const SCEV *It, ScalarEvolution &SE) const;
401 static const SCEV *evaluateAtIteration(ArrayRef<const SCEV *> Operands,
666 void push(const SCEV *S) { in push()
754 SmallDenseMap<const SCEV *, const SCEV *> RewriteResults;
759 const SCEV *visit(const SCEV *S) { in visit()
904 static const SCEV *rewrite(const SCEV *Scev, ScalarEvolution &SE, in rewrite()
[all …]
H A DDelinearization.h26 class SCEV; variable
32 SmallVectorImpl<const SCEV *> &Terms,
33 SmallVectorImpl<const SCEV *> &Sizes,
34 const SCEV *ElementSize);
38 void collectParametricTerms(ScalarEvolution &SE, const SCEV *Expr,
39 SmallVectorImpl<const SCEV *> &Terms);
43 void computeAccessFunctions(ScalarEvolution &SE, const SCEV *Expr,
110 void delinearize(ScalarEvolution &SE, const SCEV *Expr,
111 SmallVectorImpl<const SCEV *> &Subscripts,
112 SmallVectorImpl<const SCEV *> &Sizes, const SCEV *ElementSize);
[all …]
H A DScalarEvolutionDivision.h20 class SCEV; variable
30 static void divide(ScalarEvolution &SE, const SCEV *Numerator,
31 const SCEV *Denominator, const SCEV **Quotient,
32 const SCEV **Remainder);
60 SCEVDivision(ScalarEvolution &S, const SCEV *Numerator,
61 const SCEV *Denominator);
65 void cannotDivide(const SCEV *Numerator);
68 const SCEV *Denominator, *Quotient, *Remainder, *Zero, *One;
H A DLoopCacheAnalysis.h31 class SCEV; variable
57 const SCEV *getBasePointer() const { return BasePointer; } in getBasePointer()
59 const SCEV *getSubscript(unsigned SubNum) const { in getSubscript()
63 const SCEV *getFirstSubscript() const { in getFirstSubscript()
67 const SCEV *getLastSubscript() const { in getLastSubscript()
103 bool tryDelinearizeFixedSize(const SCEV *AccessFn,
124 const SCEV *getLastCoefficient() const;
128 bool isCoeffForLoopZeroOrInvariant(const SCEV &Subscript,
147 const SCEV *BasePointer = nullptr;
150 SmallVector<const SCEV *, 3> Subscripts;
[all …]
H A DScalarEvolutionNormalization.h45 class SCEV; variable
55 const SCEV *normalizeForPostIncUse(const SCEV *S, const PostIncLoopSet &Loops,
61 const SCEV *normalizeForPostIncUseIf(const SCEV *S, NormalizePredTy Pred,
66 const SCEV *denormalizeForPostIncUse(const SCEV *S, const PostIncLoopSet &Loops,
H A DLoopAccessAnalysis.h30 class SCEV; variable
362 bool addPointer(unsigned Index, const SCEV *Start, const SCEV *End,
367 const SCEV *High;
370 const SCEV *Low;
386 const SCEV *SrcStart;
391 PointerDiffInfo(const SCEV *SrcStart, const SCEV *SinkStart, in PointerDiffInfo()
408 const SCEV *Start;
411 const SCEV *End;
420 const SCEV *Expr;
424 PointerInfo(Value *PointerValue, const SCEV *Start, const SCEV *End, in PointerInfo()
[all …]
/freebsd-14.2/contrib/llvm-project/llvm/lib/Analysis/
H A DDelinearization.cpp55 bool follow(const SCEV *S) { in follow()
70 bool follow(const SCEV *S) { in follow()
95 bool follow(const SCEV *S) { in follow()
130 bool follow(const SCEV *S) { in follow()
221 const SCEV *Q, *R; in findArrayDimensionsRec()
244 for (const SCEV *T : Terms) in containsParameters()
258 static const SCEV *removeConstantFactors(ScalarEvolution &SE, const SCEV *T) { in removeConstantFactors()
300 llvm::sort(Terms, [](const SCEV *LHS, const SCEV *RHS) { in findArrayDimensions()
307 const SCEV *Q, *R; in findArrayDimensions()
352 const SCEV *Res = Expr; in computeAccessFunctions()
[all …]
H A DScalarEvolution.cpp1079 const SCEV *visit(const SCEV *S) { in getLosslessPtrToIntExpr()
1808 (SCEV::NoWrapFlags)(SCEV::FlagNSW | SCEV::FlagNUW), in getZeroExtendExprImpl()
1981 (SCEV::NoWrapFlags)(SCEV::FlagNSW | SCEV::FlagNUW), in getSignExtendExprImpl()
2301 const SCEV *(ScalarEvolution::*Operation)(const SCEV *, const SCEV *, in willNotOverflow()
3826 SCEV::NoWrapFlags Flags = IsNSW ? SCEV::FlagNSW : SCEV::FlagAnyWrap; in getAbsExpr()
4388 const SCEV *ScalarEvolution::getUMinExpr(const SCEV *LHS, const SCEV *RHS, in getUMinExpr()
4672 const SCEV *ScalarEvolution::getMinusSCEV(const SCEV *LHS, const SCEV *RHS, in getMinusSCEV()
10793 std::pair<const SCEV *, const SCEV *>
11368 auto NoWrapFlags = SCEV::NoWrapFlags(SCEV::FlagNUW | SCEV::FlagNW); in isLoopBackedgeGuardedByCond()
14041 auto GetDelta = [&](const SCEV *Old, const SCEV *New) -> const SCEV * { in verify()
[all …]
H A DScalarEvolutionNormalization.cpp43 const SCEV *visitAddRecExpr(const SCEVAddRecExpr *Expr);
47 const SCEV *
49 SmallVector<const SCEV *, 8> Operands; in visitAddRecExpr()
52 [&](const SCEV *Op) { return visit(Op); }); in visitAddRecExpr()
55 return SE.getAddRecExpr(Operands, AR->getLoop(), SCEV::FlagAnyWrap); in visitAddRecExpr()
94 return SE.getAddRecExpr(Operands, AR->getLoop(), SCEV::FlagAnyWrap); in visitAddRecExpr()
97 const SCEV *llvm::normalizeForPostIncUse(const SCEV *S, in normalizeForPostIncUse()
106 const SCEV *Normalized = in normalizeForPostIncUse()
108 const SCEV *Denormalized = denormalizeForPostIncUse(Normalized, Loops, SE); in normalizeForPostIncUse()
115 const SCEV *llvm::normalizeForPostIncUseIf(const SCEV *S, NormalizePredTy Pred, in normalizeForPostIncUseIf()
[all …]
H A DDependenceAnalysis.cpp1183 bool DependenceInfo::testZIV(const SCEV *Src, const SCEV *Dst, in testZIV()
1367 const SCEV *Coeff, const SCEV *SrcConst, const SCEV *DstConst, in weakCrossingSIVtest()
2294 bool DependenceInfo::testRDIV(const SCEV *Src, const SCEV *Dst, in testRDIV()
2360 bool DependenceInfo::testMIV(const SCEV *Src, const SCEV *Dst, in testMIV()
2402 bool DependenceInfo::gcdMIVtest(const SCEV *Src, const SCEV *Dst, in gcdMIVtest()
2611 const SCEV *A0; in banerjeeMIVtest()
2614 const SCEV *B0; in banerjeeMIVtest()
2984 const SCEV *DependenceInfo::getPositivePart(const SCEV *X) const { in getPositivePart()
3081 const SCEV *DependenceInfo::findCoefficient(const SCEV *Expr, in findCoefficient()
3097 const SCEV *DependenceInfo::zeroCoefficient(const SCEV *Expr, in zeroCoefficient()
[all …]
H A DScalarEvolutionDivision.cpp30 static inline int sizeOfSCEV(const SCEV *S) { in sizeOfSCEV()
36 bool follow(const SCEV *S) { in sizeOfSCEV()
56 const SCEV *Denominator, const SCEV **Quotient, in divide()
85 const SCEV *Q, *R; in divide()
87 for (const SCEV *Op : T->operands()) { in divide()
134 const SCEV *StartQ, *StartR, *StepQ, *StepR; in visitAddRecExpr()
151 SmallVector<const SCEV *, 2> Qs, Rs; in visitAddExpr()
155 const SCEV *Q, *R; in visitAddExpr()
177 SmallVector<const SCEV *, 2> Qs; in visitMulExpr()
192 const SCEV *Q, *R; in visitMulExpr()
[all …]
H A DLoopCacheAnalysis.cpp81 static bool isOneDimensionalArray(const SCEV &AccessFn, const SCEV &ElemSize, in isOneDimensionalArray()
90 const SCEV *Start = AR->getStart(); in isOneDimensionalArray()
109 static const SCEV *computeTripCount(const Loop &L, const SCEV &ElemSize, in computeTripCount()
141 for (const SCEV *Size : R.Sizes) in operator <<()
290 const SCEV *RefCost = nullptr; in computeRefCost()
291 const SCEV *Stride = nullptr; in computeRefCost()
323 const SCEV *TripCount = in computeRefCost()
347 const SCEV *AccessFn, SmallVectorImpl<const SCEV *> &Subscripts) { in tryDelinearizeFixedSize()
376 const SCEV *AccessFn = in delinearize()
476 const SCEV *ElemSize = Sizes.back(); in isConsecutive()
[all …]
H A DLoopAccessAnalysis.cpp165 const SCEV *StrideSCEV = SI->second; in replaceSymbolicStrideSCEV()
212 const SCEV *ScStart; in insert()
213 const SCEV *ScEnd; in insert()
405 static const SCEV *getMinFromExprs(const SCEV *I, const SCEV *J, in getMinFromExprs()
897 const SCEV *Scev = SE->getSCEV(Ptr); in findForkedSCEVs()
910 auto GetBinOpExpr = [&SE](unsigned Opcode, const SCEV *L, const SCEV *R) { in findForkedSCEVs()
1081 const SCEV *PtrExpr = get<0>(P); in createCheckForAccess()
1845 const SCEV *CastedDist = &Dist; in isSafeDependenceDistance()
1846 const SCEV *CastedProduct = Product; in isSafeDependenceDistance()
2728 const SCEV *S = SE->getSCEV(V); in isInvariant()
[all …]
H A DScalarEvolutionAliasAnalysis.cpp28 const SCEV *A, const SCEV *B) { in canComputePointerDiff()
46 const SCEV *AS = SE.getSCEV(const_cast<Value *>(LocA.Ptr)); in alias()
47 const SCEV *BS = SE.getSCEV(const_cast<Value *>(LocB.Ptr)); in alias()
65 const SCEV *BA = SE.getMinusSCEV(BS, AS); in alias()
80 const SCEV *AB = SE.getMinusSCEV(AS, BS); in alias()
114 Value *SCEVAAResult::GetBaseValue(const SCEV *S) { in GetBaseValue()
121 const SCEV *Last = A->getOperand(A->getNumOperands() - 1); in GetBaseValue()
/freebsd-14.2/contrib/llvm-project/llvm/lib/Transforms/Scalar/
H A DInductiveRangeCheckElimination.cpp147 const SCEV *Begin = nullptr;
148 const SCEV *Step = nullptr;
149 const SCEV *End = nullptr;
199 const SCEV *Begin;
200 const SCEV *End;
203 Range(const SCEV *Begin, const SCEV *End) : Begin(Begin), End(End) { in Range()
432 const SCEV *RHS) -> const SCEV * { in reassociateSubLHS()
433 const SCEV *(ScalarEvolution::*Operation)(const SCEV *, const SCEV *, in reassociateSubLHS()
506 const SCEV *End = nullptr; in extractRangeChecksFromCond()
557 static const SCEV *NoopOrExtend(const SCEV *S, Type *Ty, ScalarEvolution &SE, in NoopOrExtend()
[all …]
H A DLoopStrengthReduce.cpp386 const SCEV *ScaledReg = nullptr;
463 for (const SCEV *S : MyBad) in DoInitialMatch()
696 static const SCEV *getExactSDiv(const SCEV *LHS, const SCEV *RHS, in getExactSDiv()
1630 for (const SCEV *S : OldRegs) in RecomputeRegs()
1904 const SCEV *IncExpr;
2615 const SCEV *Copy = Expr; in getUse()
2802 static const SCEV *getExprBase(const SCEV *S) { in getExprBase()
3599 static const SCEV *CollectSubexprs(const SCEV *S, const SCEVConstant *C, in CollectSubexprs()
3645 const SCEV *Remainder = in CollectSubexprs()
4146 static const SCEV *
[all …]
H A DAlignmentFromAssumptions.cpp50 static MaybeAlign getNewAlignmentDiff(const SCEV *DiffSCEV, in getNewAlignmentDiff()
51 const SCEV *AlignSCEV, in getNewAlignmentDiff()
54 const SCEV *DiffUnitsSCEV = SE->getURemExpr(DiffSCEV, AlignSCEV); in getNewAlignmentDiff()
82 static Align getNewAlignment(const SCEV *AASCEV, const SCEV *AlignSCEV, in getNewAlignment()
83 const SCEV *OffSCEV, Value *Ptr, in getNewAlignment()
85 const SCEV *PtrSCEV = SE->getSCEV(Ptr); in getNewAlignment()
87 const SCEV *DiffSCEV = SE->getMinusSCEV(PtrSCEV, AASCEV); in getNewAlignment()
116 const SCEV *DiffStartSCEV = DiffARSCEV->getStart(); in getNewAlignment()
117 const SCEV *DiffIncSCEV = DiffARSCEV->getStepRecurrence(*SE); in getNewAlignment()
192 const SCEV *AlignSCEV, *OffSCEV; in processAssumption()
[all …]
H A DNaryReassociate.cpp228 const SCEV *OrigSCEV = nullptr; in doOneIteration()
237 const SCEV *NewSCEV = SE->getSCEV(NewI); in doOneIteration()
400 SmallVector<const SCEV *, 4> IndexExprs; in tryReassociateGEPAtIndex()
487 const SCEV *RHSExpr = SE->getSCEV(RHS); in tryReassociateBinaryOp()
617 const SCEV *BExpr, Value *C, in tryReassociateMinOrMax()
618 const SCEV *CExpr) -> Value * { in tryReassociateMinOrMax()
619 SmallVector<const SCEV *, 2> Ops1{BExpr, AExpr}; in tryReassociateMinOrMax()
630 SmallVector<const SCEV *, 2> Ops2{SE->getUnknown(C), in tryReassociateMinOrMax()
643 const SCEV *AExpr = SE->getSCEV(A); in tryReassociateMinOrMax()
644 const SCEV *BExpr = SE->getSCEV(B); in tryReassociateMinOrMax()
[all …]
H A DLoopPredication.cpp251 const SCEV *Limit;
253 const SCEV *Limit) in LoopICmp()
274 bool isSupportedStep(const SCEV* Step);
293 bool isLoopInvariantValue(const SCEV* S);
297 const SCEV *RHS);
354 const SCEV *LHSS = SE->getSCEV(LHS); in parseLoopICmp()
357 const SCEV *RHSS = SE->getSCEV(RHS); in parseLoopICmp()
496 for (const SCEV *Op : Ops) in findInsertPt()
551 const SCEV *GuardLimit = RangeCheck.Limit; in widenICmpRangeCheckIncrementingLoop()
571 const SCEV *RHS = in widenICmpRangeCheckIncrementingLoop()
[all …]
/freebsd-14.2/contrib/llvm-project/llvm/include/llvm/Transforms/Scalar/
H A DNaryReassociate.h96 class SCEV; variable
117 Instruction *tryReassociate(Instruction *I, const SCEV *&OrigSCEV);
146 Instruction *tryReassociatedBinaryOp(const SCEV *LHS, Value *RHS,
153 const SCEV *getBinarySCEV(BinaryOperator *I, const SCEV *LHS,
154 const SCEV *RHS);
158 Instruction *findClosestMatchingDominator(const SCEV *CandidateExpr,
167 const SCEV *&OrigSCEV);
196 DenseMap<const SCEV *, SmallVector<WeakTrackingVH, 2>> SeenExprs;
/freebsd-14.2/contrib/llvm-project/llvm/include/llvm/Transforms/Utils/
H A DScalarEvolutionExpander.h34 explicit SCEVOperand(unsigned Opc, int Idx, const SCEV *S) : in SCEVOperand()
41 const SCEV* S;
77 DenseMap<const SCEV *, const Loop *> RelevantLoops;
233 SmallPtrSet<const SCEV *, 8> Processed;
270 bool isSafeToExpand(const SCEV *S) const;
427 Value *expandAddToGEP(const SCEV *Op, Value *V);
433 const SCEV *S, const Instruction *InsertPt,
436 Value *expand(const SCEV *S);
437 Value *expand(const SCEV *S, BasicBlock::iterator I) {
441 Value *expand(const SCEV *S, Instruction *I) {
[all …]
/freebsd-14.2/contrib/llvm-project/llvm/lib/Transforms/Utils/
H A DScalarEvolutionExpander.cpp276 if (Flags & SCEV::FlagNUW) in InsertBinop()
278 if (Flags & SCEV::FlagNSW) in InsertBinop()
732 ScalarEvolution::maskFlags(*Flags, SCEV::FlagNUW) == SCEV::FlagNUW); in hoistIVInc()
734 ScalarEvolution::maskFlags(*Flags, SCEV::FlagNSW) == SCEV::FlagNSW); in hoistIVInc()
851 const SCEV *ExtendAfterOp = in IsIncrementNSW()
865 const SCEV *ExtendAfterOp = in IsIncrementNUW()
1267 const SCEV *NewS = S; in visitAddRecExpr()
1484 ScalarEvolution::maskFlags(*Flags, SCEV::FlagNUW) == SCEV::FlagNUW); in expand()
1486 ScalarEvolution::maskFlags(*Flags, SCEV::FlagNSW) == SCEV::FlagNSW); in expand()
1876 const SCEV *S = WorkItem.S; in isHighCostExpansionHelper()
[all …]
H A DLoopConstrainer.cpp19 static bool isSafeDecreasingBound(const SCEV *Start, const SCEV *BoundSCEV, in isSafeDecreasingBound()
56 const SCEV *MinusOne = in isSafeDecreasingBound()
65 static bool isSafeIncreasingBound(const SCEV *Start, const SCEV *BoundSCEV, in isSafeIncreasingBound()
111 const SCEV *FromBlock = in getNarrowestLatchMaxTakenCountEstimate()
172 const SCEV *LeftSCEV = SE.getSCEV(LeftValue); in parseLoopStructure()
191 if (AR->getNoWrapFlags(SCEV::FlagNSW)) in parseLoopStructure()
202 const SCEV *ExtendedStep = in parseLoopStructure()
213 return AR->getNoWrapFlags(SCEV::FlagNSW) != SCEV::FlagAnyWrap; in parseLoopStructure()
246 const SCEV *Step = SE.getSCEV(StepCI); in parseLoopStructure()
248 const SCEV *FixedRightSCEV = nullptr; in parseLoopStructure()
[all …]

1234