Lines Matching refs:Ops

846 static void GroupByComplexity(SmallVectorImpl<const SCEV *> &Ops,  in GroupByComplexity()  argument
848 if (Ops.size() < 2) return; // Noop in GroupByComplexity()
859 if (Ops.size() == 2) { in GroupByComplexity()
862 const SCEV *&LHS = Ops[0], *&RHS = Ops[1]; in GroupByComplexity()
869 llvm::stable_sort(Ops, [&](const SCEV *LHS, const SCEV *RHS) { in GroupByComplexity()
877 for (unsigned i = 0, e = Ops.size(); i != e-2; ++i) { in GroupByComplexity()
878 const SCEV *S = Ops[i]; in GroupByComplexity()
883 for (unsigned j = i+1; j != e && Ops[j]->getSCEVType() == Complexity; ++j) { in GroupByComplexity()
884 if (Ops[j] == S) { // Found a duplicate. in GroupByComplexity()
886 std::swap(Ops[i+1], Ops[j]); in GroupByComplexity()
896 static bool hasHugeExpression(ArrayRef<const SCEV *> Ops) { in hasHugeExpression() argument
897 return any_of(Ops, [](const SCEV *S) { in hasHugeExpression()
1803 SmallVector<const SCEV *, 4> Ops; in getZeroExtendExpr() local
1805 Ops.push_back(getZeroExtendExpr(Op, Ty, Depth + 1)); in getZeroExtendExpr()
1806 return getAddExpr(Ops, SCEV::FlagNUW, Depth + 1); in getZeroExtendExpr()
1836 SmallVector<const SCEV *, 4> Ops; in getZeroExtendExpr() local
1838 Ops.push_back(getZeroExtendExpr(Op, Ty, Depth + 1)); in getZeroExtendExpr()
1839 return getMulExpr(Ops, SCEV::FlagNUW, Depth + 1); in getZeroExtendExpr()
1936 SmallVector<const SCEV *, 4> Ops; in getSignExtendExpr() local
1938 Ops.push_back(getSignExtendExpr(Op, Ty, Depth + 1)); in getSignExtendExpr()
1939 return getAddExpr(Ops, SCEV::FlagNSW, Depth + 1); in getSignExtendExpr()
2150 SmallVector<const SCEV *, 4> Ops; in getAnyExtendExpr() local
2152 Ops.push_back(getAnyExtendExpr(Op, Ty)); in getAnyExtendExpr()
2153 return getAddRecExpr(Ops, AR->getLoop(), SCEV::FlagNW); in getAnyExtendExpr()
2191 const SCEV *const *Ops, size_t NumOperands, in CollectAddOperandsWithScales() argument
2198 while (const SCEVConstant *C = dyn_cast<SCEVConstant>(Ops[i])) { in CollectAddOperandsWithScales()
2209 const SCEVMulExpr *Mul = dyn_cast<SCEVMulExpr>(Ops[i]); in CollectAddOperandsWithScales()
2238 M.insert({Ops[i], Scale}); in CollectAddOperandsWithScales()
2333 const ArrayRef<const SCEV *> Ops, in StrengthenNoWrapFlags() argument
2353 if (SignOrUnsignWrap == SCEV::FlagNSW && all_of(Ops, IsKnownNonNegative)) in StrengthenNoWrapFlags()
2360 (Type == scAddExpr || Type == scMulExpr) && Ops.size() == 2 && in StrengthenNoWrapFlags()
2361 isa<SCEVConstant>(Ops[0])) { in StrengthenNoWrapFlags()
2374 const APInt &C = cast<SCEVConstant>(Ops[0])->getAPInt(); in StrengthenNoWrapFlags()
2380 if (NSWRegion.contains(SE->getSignedRange(Ops[1]))) in StrengthenNoWrapFlags()
2388 if (NUWRegion.contains(SE->getUnsignedRange(Ops[1]))) in StrengthenNoWrapFlags()
2401 const SCEV *ScalarEvolution::getAddExpr(SmallVectorImpl<const SCEV *> &Ops, in getAddExpr() argument
2406 assert(!Ops.empty() && "Cannot get empty add!"); in getAddExpr()
2407 if (Ops.size() == 1) return Ops[0]; in getAddExpr()
2409 Type *ETy = getEffectiveSCEVType(Ops[0]->getType()); in getAddExpr()
2410 for (unsigned i = 1, e = Ops.size(); i != e; ++i) in getAddExpr()
2411 assert(getEffectiveSCEVType(Ops[i]->getType()) == ETy && in getAddExpr()
2414 Ops, [](const SCEV *Op) { return Op->getType()->isPointerTy(); }); in getAddExpr()
2419 GroupByComplexity(Ops, &LI, DT); in getAddExpr()
2423 if (const SCEVConstant *LHSC = dyn_cast<SCEVConstant>(Ops[0])) { in getAddExpr()
2425 assert(Idx < Ops.size()); in getAddExpr()
2426 while (const SCEVConstant *RHSC = dyn_cast<SCEVConstant>(Ops[Idx])) { in getAddExpr()
2428 Ops[0] = getConstant(LHSC->getAPInt() + RHSC->getAPInt()); in getAddExpr()
2429 if (Ops.size() == 2) return Ops[0]; in getAddExpr()
2430 Ops.erase(Ops.begin()+1); // Erase the folded element in getAddExpr()
2431 LHSC = cast<SCEVConstant>(Ops[0]); in getAddExpr()
2436 Ops.erase(Ops.begin()); in getAddExpr()
2440 if (Ops.size() == 1) return Ops[0]; in getAddExpr()
2444 auto ComputeFlags = [this, OrigFlags](const ArrayRef<const SCEV *> Ops) { in getAddExpr() argument
2445 return StrengthenNoWrapFlags(this, scAddExpr, Ops, OrigFlags); in getAddExpr()
2449 if (Depth > MaxArithDepth || hasHugeExpression(Ops)) in getAddExpr()
2450 return getOrCreateAddExpr(Ops, ComputeFlags(Ops)); in getAddExpr()
2452 if (SCEV *S = std::get<0>(findExistingSCEVInCache(scAddExpr, Ops))) { in getAddExpr()
2456 Add->setNoWrapFlags(ComputeFlags(Ops)); in getAddExpr()
2463 Type *Ty = Ops[0]->getType(); in getAddExpr()
2465 for (unsigned i = 0, e = Ops.size(); i != e-1; ++i) in getAddExpr()
2466 if (Ops[i] == Ops[i+1]) { // X + Y + Y --> X + Y*2 in getAddExpr()
2469 while (i+Count != e && Ops[i+Count] == Ops[i]) in getAddExpr()
2473 const SCEV *Mul = getMulExpr(Scale, Ops[i], SCEV::FlagAnyWrap, Depth + 1); in getAddExpr()
2474 if (Ops.size() == Count) in getAddExpr()
2476 Ops[i] = Mul; in getAddExpr()
2477 Ops.erase(Ops.begin()+i+1, Ops.begin()+i+Count); in getAddExpr()
2482 return getAddExpr(Ops, OrigFlags, Depth + 1); in getAddExpr()
2493 if (auto *T = dyn_cast<SCEVTruncateExpr>(Ops[Idx])) in getAddExpr()
2495 if (const auto *Mul = dyn_cast<SCEVMulExpr>(Ops[Idx])) { in getAddExpr()
2507 for (unsigned i = 0, e = Ops.size(); i != e; ++i) { in getAddExpr()
2508 if (const SCEVTruncateExpr *T = dyn_cast<SCEVTruncateExpr>(Ops[i])) { in getAddExpr()
2514 } else if (const SCEVConstant *C = dyn_cast<SCEVConstant>(Ops[i])) { in getAddExpr()
2516 } else if (const SCEVMulExpr *M = dyn_cast<SCEVMulExpr>(Ops[i])) { in getAddExpr()
2549 if (Ops.size() == 2) { in getAddExpr()
2553 const SCEV *A = Ops[0]; in getAddExpr()
2554 const SCEV *B = Ops[1]; in getAddExpr()
2592 while (Idx < Ops.size() && Ops[Idx]->getSCEVType() < scAddExpr) in getAddExpr()
2596 if (Idx < Ops.size()) { in getAddExpr()
2602 while (const SCEVAddExpr *Add = dyn_cast<SCEVAddExpr>(Ops[Idx])) { in getAddExpr()
2603 if (Ops.size() > AddOpsInlineThreshold || in getAddExpr()
2608 Ops.erase(Ops.begin()+Idx); in getAddExpr()
2609 Ops.append(Add->op_begin(), Add->op_end()); in getAddExpr()
2618 return getAddExpr(Ops, CommonFlags, Depth + 1); in getAddExpr()
2622 while (Idx < Ops.size() && Ops[Idx]->getSCEVType() < scMulExpr) in getAddExpr()
2627 if (Idx < Ops.size() && isa<SCEVMulExpr>(Ops[Idx])) { in getAddExpr()
2633 Ops.data(), Ops.size(), in getAddExpr()
2648 Ops.clear(); in getAddExpr()
2650 Ops.push_back(getConstant(AccumulatedConstant)); in getAddExpr()
2653 Ops.push_back(getAddExpr(MulOp.second, SCEV::FlagAnyWrap, Depth + 1)); in getAddExpr()
2655 Ops.push_back(getMulExpr( in getAddExpr()
2661 if (Ops.empty()) in getAddExpr()
2663 if (Ops.size() == 1) in getAddExpr()
2664 return Ops[0]; in getAddExpr()
2665 return getAddExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getAddExpr()
2672 for (; Idx < Ops.size() && isa<SCEVMulExpr>(Ops[Idx]); ++Idx) { in getAddExpr()
2673 const SCEVMulExpr *Mul = cast<SCEVMulExpr>(Ops[Idx]); in getAddExpr()
2678 for (unsigned AddOp = 0, e = Ops.size(); AddOp != e; ++AddOp) in getAddExpr()
2679 if (MulOpSCEV == Ops[AddOp]) { in getAddExpr()
2694 if (Ops.size() == 2) return OuterMul; in getAddExpr()
2696 Ops.erase(Ops.begin()+AddOp); in getAddExpr()
2697 Ops.erase(Ops.begin()+Idx-1); in getAddExpr()
2699 Ops.erase(Ops.begin()+Idx); in getAddExpr()
2700 Ops.erase(Ops.begin()+AddOp-1); in getAddExpr()
2702 Ops.push_back(OuterMul); in getAddExpr()
2703 return getAddExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getAddExpr()
2708 OtherMulIdx < Ops.size() && isa<SCEVMulExpr>(Ops[OtherMulIdx]); in getAddExpr()
2710 const SCEVMulExpr *OtherMul = cast<SCEVMulExpr>(Ops[OtherMulIdx]); in getAddExpr()
2736 if (Ops.size() == 2) return OuterMul; in getAddExpr()
2737 Ops.erase(Ops.begin()+Idx); in getAddExpr()
2738 Ops.erase(Ops.begin()+OtherMulIdx-1); in getAddExpr()
2739 Ops.push_back(OuterMul); in getAddExpr()
2740 return getAddExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getAddExpr()
2749 while (Idx < Ops.size() && Ops[Idx]->getSCEVType() < scAddRecExpr) in getAddExpr()
2753 for (; Idx < Ops.size() && isa<SCEVAddRecExpr>(Ops[Idx]); ++Idx) { in getAddExpr()
2757 const SCEVAddRecExpr *AddRec = cast<SCEVAddRecExpr>(Ops[Idx]); in getAddExpr()
2759 for (unsigned i = 0, e = Ops.size(); i != e; ++i) in getAddExpr()
2760 if (isAvailableAtLoopEntry(Ops[i], AddRecLoop)) { in getAddExpr()
2761 LIOps.push_back(Ops[i]); in getAddExpr()
2762 Ops.erase(Ops.begin()+i); in getAddExpr()
2790 if (Ops.size() == 1) return NewRec; in getAddExpr()
2794 if (Ops[i] == AddRec) { in getAddExpr()
2795 Ops[i] = NewRec; in getAddExpr()
2798 return getAddExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getAddExpr()
2805 OtherIdx < Ops.size() && isa<SCEVAddRecExpr>(Ops[OtherIdx]); in getAddExpr()
2810 cast<SCEVAddRecExpr>(Ops[OtherIdx])->getLoop()->getHeader(), in getAddExpr()
2813 if (AddRecLoop == cast<SCEVAddRecExpr>(Ops[OtherIdx])->getLoop()) { in getAddExpr()
2816 for (; OtherIdx != Ops.size() && isa<SCEVAddRecExpr>(Ops[OtherIdx]); in getAddExpr()
2818 const auto *OtherAddRec = cast<SCEVAddRecExpr>(Ops[OtherIdx]); in getAddExpr()
2831 Ops.erase(Ops.begin() + OtherIdx); --OtherIdx; in getAddExpr()
2835 Ops[Idx] = getAddRecExpr(AddRecOps, AddRecLoop, SCEV::FlagAnyWrap); in getAddExpr()
2836 return getAddExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getAddExpr()
2846 return getOrCreateAddExpr(Ops, ComputeFlags(Ops)); in getAddExpr()
2850 ScalarEvolution::getOrCreateAddExpr(ArrayRef<const SCEV *> Ops, in getOrCreateAddExpr() argument
2854 for (const SCEV *Op : Ops) in getOrCreateAddExpr()
2860 const SCEV **O = SCEVAllocator.Allocate<const SCEV *>(Ops.size()); in getOrCreateAddExpr()
2861 std::uninitialized_copy(Ops.begin(), Ops.end(), O); in getOrCreateAddExpr()
2863 SCEVAddExpr(ID.Intern(SCEVAllocator), O, Ops.size()); in getOrCreateAddExpr()
2872 ScalarEvolution::getOrCreateAddRecExpr(ArrayRef<const SCEV *> Ops, in getOrCreateAddRecExpr() argument
2876 for (unsigned i = 0, e = Ops.size(); i != e; ++i) in getOrCreateAddRecExpr()
2877 ID.AddPointer(Ops[i]); in getOrCreateAddRecExpr()
2883 const SCEV **O = SCEVAllocator.Allocate<const SCEV *>(Ops.size()); in getOrCreateAddRecExpr()
2884 std::uninitialized_copy(Ops.begin(), Ops.end(), O); in getOrCreateAddRecExpr()
2886 SCEVAddRecExpr(ID.Intern(SCEVAllocator), O, Ops.size(), L); in getOrCreateAddRecExpr()
2895 ScalarEvolution::getOrCreateMulExpr(ArrayRef<const SCEV *> Ops, in getOrCreateMulExpr() argument
2899 for (unsigned i = 0, e = Ops.size(); i != e; ++i) in getOrCreateMulExpr()
2900 ID.AddPointer(Ops[i]); in getOrCreateMulExpr()
2905 const SCEV **O = SCEVAllocator.Allocate<const SCEV *>(Ops.size()); in getOrCreateMulExpr()
2906 std::uninitialized_copy(Ops.begin(), Ops.end(), O); in getOrCreateMulExpr()
2908 O, Ops.size()); in getOrCreateMulExpr()
2971 const SCEV *ScalarEvolution::getMulExpr(SmallVectorImpl<const SCEV *> &Ops, in getMulExpr() argument
2976 assert(!Ops.empty() && "Cannot get empty mul!"); in getMulExpr()
2977 if (Ops.size() == 1) return Ops[0]; in getMulExpr()
2979 Type *ETy = Ops[0]->getType(); in getMulExpr()
2981 for (unsigned i = 1, e = Ops.size(); i != e; ++i) in getMulExpr()
2982 assert(Ops[i]->getType() == ETy && in getMulExpr()
2987 GroupByComplexity(Ops, &LI, DT); in getMulExpr()
2991 if (const SCEVConstant *LHSC = dyn_cast<SCEVConstant>(Ops[0])) { in getMulExpr()
2993 assert(Idx < Ops.size()); in getMulExpr()
2994 while (const SCEVConstant *RHSC = dyn_cast<SCEVConstant>(Ops[Idx])) { in getMulExpr()
2996 Ops[0] = getConstant(LHSC->getAPInt() * RHSC->getAPInt()); in getMulExpr()
2997 if (Ops.size() == 2) return Ops[0]; in getMulExpr()
2998 Ops.erase(Ops.begin()+1); // Erase the folded element in getMulExpr()
2999 LHSC = cast<SCEVConstant>(Ops[0]); in getMulExpr()
3008 Ops.erase(Ops.begin()); in getMulExpr()
3012 if (Ops.size() == 1) in getMulExpr()
3013 return Ops[0]; in getMulExpr()
3017 auto ComputeFlags = [this, OrigFlags](const ArrayRef<const SCEV *> Ops) { in getMulExpr() argument
3018 return StrengthenNoWrapFlags(this, scMulExpr, Ops, OrigFlags); in getMulExpr()
3022 if (Depth > MaxArithDepth || hasHugeExpression(Ops)) in getMulExpr()
3023 return getOrCreateMulExpr(Ops, ComputeFlags(Ops)); in getMulExpr()
3025 if (SCEV *S = std::get<0>(findExistingSCEVInCache(scMulExpr, Ops))) { in getMulExpr()
3029 Mul->setNoWrapFlags(ComputeFlags(Ops)); in getMulExpr()
3033 if (const SCEVConstant *LHSC = dyn_cast<SCEVConstant>(Ops[0])) { in getMulExpr()
3034 if (Ops.size() == 2) { in getMulExpr()
3036 if (const SCEVAddExpr *Add = dyn_cast<SCEVAddExpr>(Ops[1])) in getMulExpr()
3050 if (Ops[0]->isAllOnesValue()) { in getMulExpr()
3053 if (const SCEVAddExpr *Add = dyn_cast<SCEVAddExpr>(Ops[1])) { in getMulExpr()
3057 const SCEV *Mul = getMulExpr(Ops[0], AddOp, SCEV::FlagAnyWrap, in getMulExpr()
3064 } else if (const auto *AddRec = dyn_cast<SCEVAddRecExpr>(Ops[1])) { in getMulExpr()
3068 Operands.push_back(getMulExpr(Ops[0], AddRecOp, SCEV::FlagAnyWrap, in getMulExpr()
3079 while (Idx < Ops.size() && Ops[Idx]->getSCEVType() < scMulExpr) in getMulExpr()
3083 if (Idx < Ops.size()) { in getMulExpr()
3085 while (const SCEVMulExpr *Mul = dyn_cast<SCEVMulExpr>(Ops[Idx])) { in getMulExpr()
3086 if (Ops.size() > MulOpsInlineThreshold) in getMulExpr()
3090 Ops.erase(Ops.begin()+Idx); in getMulExpr()
3091 Ops.append(Mul->op_begin(), Mul->op_end()); in getMulExpr()
3099 return getMulExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getMulExpr()
3105 while (Idx < Ops.size() && Ops[Idx]->getSCEVType() < scAddRecExpr) in getMulExpr()
3109 for (; Idx < Ops.size() && isa<SCEVAddRecExpr>(Ops[Idx]); ++Idx) { in getMulExpr()
3113 const SCEVAddRecExpr *AddRec = cast<SCEVAddRecExpr>(Ops[Idx]); in getMulExpr()
3115 for (unsigned i = 0, e = Ops.size(); i != e; ++i) in getMulExpr()
3116 if (isAvailableAtLoopEntry(Ops[i], AddRecLoop)) { in getMulExpr()
3117 LIOps.push_back(Ops[i]); in getMulExpr()
3118 Ops.erase(Ops.begin()+i); in getMulExpr()
3142 if (Ops.size() == 1) return NewRec; in getMulExpr()
3146 if (Ops[i] == AddRec) { in getMulExpr()
3147 Ops[i] = NewRec; in getMulExpr()
3150 return getMulExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getMulExpr()
3169 OtherIdx != Ops.size() && isa<SCEVAddRecExpr>(Ops[OtherIdx]); in getMulExpr()
3172 dyn_cast<SCEVAddRecExpr>(Ops[OtherIdx]); in getMulExpr()
3214 if (Ops.size() == 2) return NewAddRec; in getMulExpr()
3215 Ops[Idx] = NewAddRec; in getMulExpr()
3216 Ops.erase(Ops.begin() + OtherIdx); --OtherIdx; in getMulExpr()
3224 return getMulExpr(Ops, SCEV::FlagAnyWrap, Depth + 1); in getMulExpr()
3232 return getOrCreateMulExpr(Ops, ComputeFlags(Ops)); in getMulExpr()
3655 ArrayRef<const SCEV *> Ops) { in findExistingSCEVInCache() argument
3659 for (unsigned i = 0, e = Ops.size(); i != e; ++i) in findExistingSCEVInCache()
3660 ID.AddPointer(Ops[i]); in findExistingSCEVInCache()
3671 SmallVectorImpl<const SCEV *> &Ops) { in getMinMaxExpr() argument
3672 assert(!Ops.empty() && "Cannot get empty (u|s)(min|max)!"); in getMinMaxExpr()
3673 if (Ops.size() == 1) return Ops[0]; in getMinMaxExpr()
3675 Type *ETy = getEffectiveSCEVType(Ops[0]->getType()); in getMinMaxExpr()
3676 for (unsigned i = 1, e = Ops.size(); i != e; ++i) { in getMinMaxExpr()
3677 assert(getEffectiveSCEVType(Ops[i]->getType()) == ETy && in getMinMaxExpr()
3679 assert(Ops[0]->getType()->isPointerTy() == in getMinMaxExpr()
3680 Ops[i]->getType()->isPointerTy() && in getMinMaxExpr()
3689 GroupByComplexity(Ops, &LI, DT); in getMinMaxExpr()
3692 if (const SCEV *S = std::get<0>(findExistingSCEVInCache(Kind, Ops))) { in getMinMaxExpr()
3698 if (const SCEVConstant *LHSC = dyn_cast<SCEVConstant>(Ops[0])) { in getMinMaxExpr()
3700 assert(Idx < Ops.size()); in getMinMaxExpr()
3713 while (const SCEVConstant *RHSC = dyn_cast<SCEVConstant>(Ops[Idx])) { in getMinMaxExpr()
3717 Ops[0] = getConstant(Fold); in getMinMaxExpr()
3718 Ops.erase(Ops.begin()+1); // Erase the folded element in getMinMaxExpr()
3719 if (Ops.size() == 1) return Ops[0]; in getMinMaxExpr()
3720 LHSC = cast<SCEVConstant>(Ops[0]); in getMinMaxExpr()
3728 Ops.erase(Ops.begin()); in getMinMaxExpr()
3736 if (Ops.size() == 1) return Ops[0]; in getMinMaxExpr()
3740 while (Idx < Ops.size() && Ops[Idx]->getSCEVType() < Kind) in getMinMaxExpr()
3745 if (Idx < Ops.size()) { in getMinMaxExpr()
3747 while (Ops[Idx]->getSCEVType() == Kind) { in getMinMaxExpr()
3748 const SCEVMinMaxExpr *SMME = cast<SCEVMinMaxExpr>(Ops[Idx]); in getMinMaxExpr()
3749 Ops.erase(Ops.begin()+Idx); in getMinMaxExpr()
3750 Ops.append(SMME->op_begin(), SMME->op_end()); in getMinMaxExpr()
3755 return getMinMaxExpr(Kind, Ops); in getMinMaxExpr()
3767 for (unsigned i = 0, e = Ops.size() - 1; i != e; ++i) { in getMinMaxExpr()
3768 if (Ops[i] == Ops[i + 1] || in getMinMaxExpr()
3769 isKnownViaNonRecursiveReasoning(FirstPred, Ops[i], Ops[i + 1])) { in getMinMaxExpr()
3772 Ops.erase(Ops.begin() + i + 1, Ops.begin() + i + 2); in getMinMaxExpr()
3775 } else if (isKnownViaNonRecursiveReasoning(SecondPred, Ops[i], in getMinMaxExpr()
3776 Ops[i + 1])) { in getMinMaxExpr()
3778 Ops.erase(Ops.begin() + i, Ops.begin() + i + 1); in getMinMaxExpr()
3784 if (Ops.size() == 1) return Ops[0]; in getMinMaxExpr()
3786 assert(!Ops.empty() && "Reduced smax down to nothing!"); in getMinMaxExpr()
3793 std::tie(ExistingSCEV, ID, IP) = findExistingSCEVInCache(Kind, Ops); in getMinMaxExpr()
3796 const SCEV **O = SCEVAllocator.Allocate<const SCEV *>(Ops.size()); in getMinMaxExpr()
3797 std::uninitialized_copy(Ops.begin(), Ops.end(), O); in getMinMaxExpr()
3799 SCEVMinMaxExpr(ID.Intern(SCEVAllocator), Kind, O, Ops.size()); in getMinMaxExpr()
3807 SmallVector<const SCEV *, 2> Ops = {LHS, RHS}; in getSMaxExpr() local
3808 return getSMaxExpr(Ops); in getSMaxExpr()
3811 const SCEV *ScalarEvolution::getSMaxExpr(SmallVectorImpl<const SCEV *> &Ops) { in getSMaxExpr() argument
3812 return getMinMaxExpr(scSMaxExpr, Ops); in getSMaxExpr()
3816 SmallVector<const SCEV *, 2> Ops = {LHS, RHS}; in getUMaxExpr() local
3817 return getUMaxExpr(Ops); in getUMaxExpr()
3820 const SCEV *ScalarEvolution::getUMaxExpr(SmallVectorImpl<const SCEV *> &Ops) { in getUMaxExpr() argument
3821 return getMinMaxExpr(scUMaxExpr, Ops); in getUMaxExpr()
3826 SmallVector<const SCEV *, 2> Ops = { LHS, RHS }; in getSMinExpr() local
3827 return getSMinExpr(Ops); in getSMinExpr()
3830 const SCEV *ScalarEvolution::getSMinExpr(SmallVectorImpl<const SCEV *> &Ops) { in getSMinExpr() argument
3831 return getMinMaxExpr(scSMinExpr, Ops); in getSMinExpr()
3836 SmallVector<const SCEV *, 2> Ops = { LHS, RHS }; in getUMinExpr() local
3837 return getUMinExpr(Ops); in getUMinExpr()
3840 const SCEV *ScalarEvolution::getUMinExpr(SmallVectorImpl<const SCEV *> &Ops) { in getUMinExpr() argument
3841 return getMinMaxExpr(scUMinExpr, Ops); in getUMinExpr()
4155 SmallVector<const SCEV *> Ops{AddRec->operands()}; in removePointerBase() local
4156 Ops[0] = removePointerBase(SE, Ops[0]); in removePointerBase()
4159 return SE->getAddRecExpr(Ops, AddRec->getLoop(), SCEV::FlagAnyWrap); in removePointerBase()
4163 SmallVector<const SCEV *> Ops{Add->operands()}; in removePointerBase() local
4165 for (const SCEV *&AddOp : Ops) { in removePointerBase()
4178 return SE->getAddExpr(Ops); in removePointerBase()
4321 SmallVector<const SCEV *, 2> Ops = { LHS, RHS }; in getUMinFromMismatchedTypes() local
4322 return getUMinFromMismatchedTypes(Ops); in getUMinFromMismatchedTypes()
4326 SmallVectorImpl<const SCEV *> &Ops) { in getUMinFromMismatchedTypes() argument
4327 assert(!Ops.empty() && "At least one operand must be!"); in getUMinFromMismatchedTypes()
4329 if (Ops.size() == 1) in getUMinFromMismatchedTypes()
4330 return Ops[0]; in getUMinFromMismatchedTypes()
4334 for (auto *S : Ops) in getUMinFromMismatchedTypes()
4343 for (auto *S : Ops) in getUMinFromMismatchedTypes()
5044 SmallVector<const SCEV *, 8> Ops; in createAddRecFromPHIWithCastsImpl() local
5047 Ops.push_back(Add->getOperand(i)); in createAddRecFromPHIWithCastsImpl()
5048 const SCEV *Accum = getAddExpr(Ops); in createAddRecFromPHIWithCastsImpl()
5366 SmallVector<const SCEV *, 8> Ops; in createAddRecFromPHI() local
5369 Ops.push_back(SCEVBackedgeConditionFolder::rewrite(Add->getOperand(i), in createAddRecFromPHI()
5371 const SCEV *Accum = getAddExpr(Ops); in createAddRecFromPHI()
7554 SmallVector<const SCEV *, 2> Ops; in getExact() local
7562 Ops.push_back(BECount); in getExact()
7571 return SE->getUMinFromMismatchedTypes(Ops); in getExact()
12127 SmallVector<const SCEV *, 3> Ops; in getPostIncExpr() local
12131 Ops.push_back(SE.getAddExpr(getOperand(i), getOperand(i + 1))); in getPostIncExpr()
12138 Ops.push_back(Last); in getPostIncExpr()
12139 return cast<SCEVAddRecExpr>(SE.getAddRecExpr(Ops, getLoop(), in getPostIncExpr()