Lines Matching refs:Depth

205                              KnownBits &Known, unsigned Depth, const Query &Q);
207 static void computeKnownBits(const Value *V, KnownBits &Known, unsigned Depth, in computeKnownBits() argument
219 computeKnownBits(V, DemandedElts, Known, Depth, Q); in computeKnownBits()
223 const DataLayout &DL, unsigned Depth, in computeKnownBits() argument
227 ::computeKnownBits(V, Known, Depth, in computeKnownBits()
233 unsigned Depth, AssumptionCache *AC, in computeKnownBits() argument
236 ::computeKnownBits(V, DemandedElts, Known, Depth, in computeKnownBits()
241 unsigned Depth, const Query &Q);
243 static KnownBits computeKnownBits(const Value *V, unsigned Depth,
247 unsigned Depth, AssumptionCache *AC, in computeKnownBits() argument
253 V, Depth, Query(DL, AC, safeCxtI(V, CxtI), DT, UseInstrInfo, ORE)); in computeKnownBits()
257 const DataLayout &DL, unsigned Depth, in computeKnownBits() argument
263 V, DemandedElts, Depth, in computeKnownBits()
324 static bool isKnownToBeAPowerOfTwo(const Value *V, bool OrZero, unsigned Depth,
328 bool OrZero, unsigned Depth, in isKnownToBeAPowerOfTwo() argument
332 V, OrZero, Depth, Query(DL, AC, safeCxtI(V, CxtI), DT, UseInstrInfo)); in isKnownToBeAPowerOfTwo()
336 unsigned Depth, const Query &Q);
338 static bool isKnownNonZero(const Value *V, unsigned Depth, const Query &Q);
340 bool llvm::isKnownNonZero(const Value *V, const DataLayout &DL, unsigned Depth, in isKnownNonZero() argument
343 return ::isKnownNonZero(V, Depth, in isKnownNonZero()
348 unsigned Depth, AssumptionCache *AC, in isKnownNonNegative() argument
352 computeKnownBits(V, DL, Depth, AC, CxtI, DT, nullptr, UseInstrInfo); in isKnownNonNegative()
356 bool llvm::isKnownPositive(const Value *V, const DataLayout &DL, unsigned Depth, in isKnownPositive() argument
364 return isKnownNonNegative(V, DL, Depth, AC, CxtI, DT, UseInstrInfo) && in isKnownPositive()
365 isKnownNonZero(V, DL, Depth, AC, CxtI, DT, UseInstrInfo); in isKnownPositive()
368 bool llvm::isKnownNegative(const Value *V, const DataLayout &DL, unsigned Depth, in isKnownNegative() argument
372 computeKnownBits(V, DL, Depth, AC, CxtI, DT, nullptr, UseInstrInfo); in isKnownNegative()
376 static bool isKnownNonEqual(const Value *V1, const Value *V2, unsigned Depth,
388 static bool MaskedValueIsZero(const Value *V, const APInt &Mask, unsigned Depth,
392 const DataLayout &DL, unsigned Depth, in MaskedValueIsZero() argument
396 V, Mask, Depth, Query(DL, AC, safeCxtI(V, CxtI), DT, UseInstrInfo)); in MaskedValueIsZero()
400 unsigned Depth, const Query &Q);
402 static unsigned ComputeNumSignBits(const Value *V, unsigned Depth, in ComputeNumSignBits() argument
412 return ComputeNumSignBits(V, DemandedElts, Depth, Q); in ComputeNumSignBits()
416 unsigned Depth, AssumptionCache *AC, in ComputeNumSignBits() argument
420 V, Depth, Query(DL, AC, safeCxtI(V, CxtI), DT, UseInstrInfo)); in ComputeNumSignBits()
424 unsigned Depth, AssumptionCache *AC, in ComputeMaxSignificantBits() argument
427 unsigned SignBits = ComputeNumSignBits(V, DL, Depth, AC, CxtI, DT); in ComputeMaxSignificantBits()
434 unsigned Depth, const Query &Q) { in computeKnownBitsAddSub() argument
435 computeKnownBits(Op1, DemandedElts, KnownOut, Depth + 1, Q); in computeKnownBitsAddSub()
442 computeKnownBits(Op0, DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsAddSub()
448 KnownBits &Known2, unsigned Depth, in computeKnownBitsMul() argument
450 computeKnownBits(Op1, DemandedElts, Known, Depth + 1, Q); in computeKnownBitsMul()
451 computeKnownBits(Op0, DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsMul()
482 isGuaranteedNotToBeUndefOrPoison(Op0, Q.AC, Q.CxtI, Q.DT, Depth + 1); in computeKnownBitsMul()
676 unsigned Depth, const Query &Q) { in computeKnownBitsFromAssume() argument
725 if (Depth == MaxAnalysisRecursionDepth) in computeKnownBitsFromAssume()
755 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
763 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
765 computeKnownBits(B, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
776 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
778 computeKnownBits(B, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
789 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
791 computeKnownBits(B, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
802 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
804 computeKnownBits(B, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
815 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
817 computeKnownBits(B, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
831 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
833 computeKnownBits(B, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
847 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
860 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
872 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
882 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
894 computeKnownBits(A, Depth + 1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
907 computeKnownBits(A, Depth + 1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
920 computeKnownBits(A, Depth + 1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
933 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
946 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
957 computeKnownBits(A, Depth+1, QueryNoAC).anyextOrTrunc(BitWidth); in computeKnownBitsFromAssume()
969 if (isKnownToBeAPowerOfTwo(A, false, Depth + 1, QueryNoAC)) in computeKnownBitsFromAssume()
1008 KnownBits &Known2, unsigned Depth, const Query &Q, in computeKnownBitsFromShiftOperator() argument
1011 computeKnownBits(I->getOperand(0), DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromShiftOperator()
1012 computeKnownBits(I->getOperand(1), DemandedElts, Known, Depth + 1, Q); in computeKnownBitsFromShiftOperator()
1056 isKnownNonZero(I->getOperand(1), DemandedElts, Depth + 1, Q); in computeKnownBitsFromShiftOperator()
1076 isKnownNonZero(I->getOperand(1), DemandedElts, Depth + 1, Q); in computeKnownBitsFromShiftOperator()
1093 KnownBits &Known, unsigned Depth, in computeKnownBitsFromOperator() argument
1107 computeKnownBits(I->getOperand(1), DemandedElts, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1108 computeKnownBits(I->getOperand(0), DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1121 computeKnownBits(Y, DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1128 computeKnownBits(I->getOperand(1), DemandedElts, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1129 computeKnownBits(I->getOperand(0), DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1134 computeKnownBits(I->getOperand(1), DemandedElts, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1135 computeKnownBits(I->getOperand(0), DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1142 Known, Known2, Depth, Q); in computeKnownBitsFromOperator()
1146 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1147 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1155 computeKnownBits(RHS, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1156 computeKnownBits(LHS, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1176 computeKnownBits(I->getOperand(2), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1177 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1218 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1228 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1267 Depth + 1, Q); in computeKnownBitsFromOperator()
1279 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1299 computeKnownBitsFromShiftOperator(I, DemandedElts, Known, Known2, Depth, Q, in computeKnownBitsFromOperator()
1311 computeKnownBitsFromShiftOperator(I, DemandedElts, Known, Known2, Depth, Q, in computeKnownBitsFromOperator()
1323 computeKnownBitsFromShiftOperator(I, DemandedElts, Known, Known2, Depth, Q, in computeKnownBitsFromOperator()
1330 DemandedElts, Known, Known2, Depth, Q); in computeKnownBitsFromOperator()
1336 DemandedElts, Known, Known2, Depth, Q); in computeKnownBitsFromOperator()
1340 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1341 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1346 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1347 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1356 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1399 computeKnownBits(Index, IndexBits, Depth + 1, Q); in computeKnownBitsFromOperator()
1465 computeKnownBits(R, DemandedElts, Known2, Depth + 1, RecQ); in computeKnownBitsFromOperator()
1505 computeKnownBits(R, Known2, Depth + 1, RecQ); in computeKnownBitsFromOperator()
1510 computeKnownBits(L, Known3, Depth + 1, RecQ); in computeKnownBitsFromOperator()
1558 if (Depth < MaxAnalysisRecursionDepth - 1 && !Known.Zero && !Known.One) { in computeKnownBitsFromOperator()
1599 computeKnownBits(RV, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1607 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1613 computeKnownBits(I->getOperand(0), DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1618 computeKnownBits(I->getOperand(0), DemandedElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1623 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1634 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1645 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1667 computeKnownBits(I->getOperand(0), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1668 computeKnownBits(I->getOperand(1), Known3, Depth + 1, Q); in computeKnownBitsFromOperator()
1679 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1680 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1708 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1709 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1713 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1714 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1718 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1719 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1723 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1724 computeKnownBits(I->getOperand(1), Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1786 computeKnownBits(LHS, DemandedLHS, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1793 computeKnownBits(RHS, DemandedRHS, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1813 computeKnownBits(Elt, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1822 computeKnownBits(Vec, DemandedVecElts, Known2, Depth + 1, Q); in computeKnownBitsFromOperator()
1842 computeKnownBits(Vec, DemandedVecElts, Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1856 Known, Known2, Depth, Q); in computeKnownBitsFromOperator()
1862 Known, Known2, Depth, Q); in computeKnownBitsFromOperator()
1867 DemandedElts, Known, Known2, Depth, Q); in computeKnownBitsFromOperator()
1875 Depth + 1)) in computeKnownBitsFromOperator()
1876 computeKnownBits(I->getOperand(0), Known, Depth + 1, Q); in computeKnownBitsFromOperator()
1884 unsigned Depth, const Query &Q) { in computeKnownBits() argument
1886 computeKnownBits(V, DemandedElts, Known, Depth, Q); in computeKnownBits()
1892 KnownBits computeKnownBits(const Value *V, unsigned Depth, const Query &Q) { in computeKnownBits() argument
1894 computeKnownBits(V, Known, Depth, Q); in computeKnownBits()
1914 KnownBits &Known, unsigned Depth, const Query &Q) { in computeKnownBits() argument
1923 assert(Depth <= MaxAnalysisRecursionDepth && "Limit Search Depth"); in computeKnownBits()
2010 if (Depth == MaxAnalysisRecursionDepth) in computeKnownBits()
2017 computeKnownBits(GA->getAliasee(), Known, Depth + 1, Q); in computeKnownBits()
2022 computeKnownBitsFromOperator(I, DemandedElts, Known, Depth, Q); in computeKnownBits()
2034 computeKnownBitsFromAssume(V, Known, Depth, Q); in computeKnownBits()
2042 unsigned Depth, Query &Q) { in isPowerOfTwoRecurrence() argument
2054 if (!isKnownToBeAPowerOfTwo(Start, OrZero, Depth, Q)) in isPowerOfTwoRecurrence()
2070 isKnownToBeAPowerOfTwo(Step, OrZero, Depth, Q); in isPowerOfTwoRecurrence()
2082 isKnownToBeAPowerOfTwo(Step, false, Depth, Q); in isPowerOfTwoRecurrence()
2100 bool isKnownToBeAPowerOfTwo(const Value *V, bool OrZero, unsigned Depth, in isKnownToBeAPowerOfTwo() argument
2102 assert(Depth <= MaxAnalysisRecursionDepth && "Limit Search Depth"); in isKnownToBeAPowerOfTwo()
2121 if (Depth++ == MaxAnalysisRecursionDepth) in isKnownToBeAPowerOfTwo()
2129 return isKnownToBeAPowerOfTwo(X, /*OrZero*/ true, Depth, Q); in isKnownToBeAPowerOfTwo()
2132 return isKnownToBeAPowerOfTwo(ZI->getOperand(0), OrZero, Depth, Q); in isKnownToBeAPowerOfTwo()
2135 return isKnownToBeAPowerOfTwo(SI->getTrueValue(), OrZero, Depth, Q) && in isKnownToBeAPowerOfTwo()
2136 isKnownToBeAPowerOfTwo(SI->getFalseValue(), OrZero, Depth, Q); in isKnownToBeAPowerOfTwo()
2140 return isKnownToBeAPowerOfTwo(X, OrZero, Depth, Q) && in isKnownToBeAPowerOfTwo()
2141 isKnownToBeAPowerOfTwo(Y, OrZero, Depth, Q); in isKnownToBeAPowerOfTwo()
2146 if (isKnownToBeAPowerOfTwo(X, /*OrZero*/ true, Depth, Q) || in isKnownToBeAPowerOfTwo()
2147 isKnownToBeAPowerOfTwo(Y, /*OrZero*/ true, Depth, Q)) in isKnownToBeAPowerOfTwo()
2163 if (isKnownToBeAPowerOfTwo(Y, OrZero, Depth, Q)) in isKnownToBeAPowerOfTwo()
2167 if (isKnownToBeAPowerOfTwo(X, OrZero, Depth, Q)) in isKnownToBeAPowerOfTwo()
2172 computeKnownBits(X, LHSBits, Depth, Q); in isKnownToBeAPowerOfTwo()
2175 computeKnownBits(Y, RHSBits, Depth, Q); in isKnownToBeAPowerOfTwo()
2193 if (isPowerOfTwoRecurrence(PN, OrZero, Depth, RecQ)) in isKnownToBeAPowerOfTwo()
2198 unsigned NewDepth = std::max(Depth, MaxAnalysisRecursionDepth - 1); in isKnownToBeAPowerOfTwo()
2217 Depth, Q); in isKnownToBeAPowerOfTwo()
2229 static bool isGEPKnownNonNull(const GEPOperator *GEP, unsigned Depth, in isGEPKnownNonNull() argument
2244 if (isKnownNonZero(GEP->getPointerOperand(), Depth, Q)) in isGEPKnownNonNull()
2280 if (Depth++ >= MaxAnalysisRecursionDepth) in isGEPKnownNonNull()
2283 if (isKnownNonZero(GTI.getOperand(), Depth, Q)) in isGEPKnownNonNull()
2434 bool isKnownNonZero(const Value *V, const APInt &DemandedElts, unsigned Depth, in isKnownNonZero() argument
2455 return isKnownNonZero(CE->getOperand(0), Depth, Q); in isKnownNonZero()
2500 if (Depth++ >= MaxAnalysisRecursionDepth) in isKnownNonZero()
2528 return isKnownNonZero(RP, Depth, Q); in isKnownNonZero()
2545 return isGEPKnownNonNull(GEP, Depth, Q); in isKnownNonZero()
2548 return isKnownNonZero(BCO->getOperand(0), Depth, Q); in isKnownNonZero()
2553 return isKnownNonZero(I2P->getOperand(0), Depth, Q); in isKnownNonZero()
2561 return isKnownNonZero(P2I->getOperand(0), Depth, Q); in isKnownNonZero()
2568 return isKnownNonZero(X, DemandedElts, Depth, Q) || in isKnownNonZero()
2569 isKnownNonZero(Y, DemandedElts, Depth, Q); in isKnownNonZero()
2573 return isKnownNonZero(cast<Instruction>(V)->getOperand(0), Depth, Q); in isKnownNonZero()
2581 return isKnownNonZero(X, Depth, Q); in isKnownNonZero()
2584 computeKnownBits(X, DemandedElts, Known, Depth, Q); in isKnownNonZero()
2594 return isKnownNonZero(X, Depth, Q); in isKnownNonZero()
2596 KnownBits Known = computeKnownBits(X, DemandedElts, Depth, Q); in isKnownNonZero()
2610 return isKnownNonZero(X, DemandedElts, Depth, Q); in isKnownNonZero()
2615 return isKnownNonZero(X, DemandedElts, Depth, Q); in isKnownNonZero()
2619 KnownBits XKnown = computeKnownBits(X, DemandedElts, Depth, Q); in isKnownNonZero()
2620 KnownBits YKnown = computeKnownBits(Y, DemandedElts, Depth, Q); in isKnownNonZero()
2625 if (isKnownNonZero(X, DemandedElts, Depth, Q) || in isKnownNonZero()
2626 isKnownNonZero(Y, DemandedElts, Depth, Q)) in isKnownNonZero()
2645 isKnownToBeAPowerOfTwo(Y, /*OrZero*/ false, Depth, Q)) in isKnownNonZero()
2648 isKnownToBeAPowerOfTwo(X, /*OrZero*/ false, Depth, Q)) in isKnownNonZero()
2657 isKnownNonZero(X, DemandedElts, Depth, Q) && in isKnownNonZero()
2658 isKnownNonZero(Y, DemandedElts, Depth, Q)) in isKnownNonZero()
2663 if (isKnownNonZero(SI->getTrueValue(), DemandedElts, Depth, Q) && in isKnownNonZero()
2664 isKnownNonZero(SI->getFalseValue(), DemandedElts, Depth, Q)) in isKnownNonZero()
2674 unsigned NewDepth = std::max(Depth, MaxAnalysisRecursionDepth - 1); in isKnownNonZero()
2692 return isKnownNonZero(Vec, DemandedVecElts, Depth, Q); in isKnownNonZero()
2698 if (isKnownNonZero(Op, Depth, Q) && in isKnownNonZero()
2699 isGuaranteedNotToBePoison(Op, Q.AC, Q.CxtI, Q.DT, Depth)) in isKnownNonZero()
2707 computeKnownBits(V, DemandedElts, Known, Depth, Q); in isKnownNonZero()
2711 bool isKnownNonZero(const Value* V, unsigned Depth, const Query& Q) { in isKnownNonZero() argument
2720 return isKnownNonZero(V, DemandedElts, Depth, Q); in isKnownNonZero()
2831 static bool isAddOfNonZero(const Value *V1, const Value *V2, unsigned Depth, in isAddOfNonZero() argument
2843 return isKnownNonZero(Op, Depth + 1, Q); in isAddOfNonZero()
2848 static bool isNonEqualMul(const Value *V1, const Value *V2, unsigned Depth, in isNonEqualMul() argument
2854 !C->isZero() && !C->isOne() && isKnownNonZero(V1, Depth + 1, Q); in isNonEqualMul()
2861 static bool isNonEqualShl(const Value *V1, const Value *V2, unsigned Depth, in isNonEqualShl() argument
2867 !C->isZero() && isKnownNonZero(V1, Depth + 1, Q); in isNonEqualShl()
2873 unsigned Depth, const Query &Q) { in isNonEqualPHIs() argument
2895 if (!isKnownNonEqual(IV1, IV2, Depth + 1, RecQ)) in isNonEqualPHIs()
2903 static bool isKnownNonEqual(const Value *V1, const Value *V2, unsigned Depth, in isKnownNonEqual() argument
2911 if (Depth >= MaxAnalysisRecursionDepth) in isKnownNonEqual()
2921 return isKnownNonEqual(Values->first, Values->second, Depth + 1, Q); in isKnownNonEqual()
2927 if (isNonEqualPHIs(PN1, PN2, Depth, Q)) in isKnownNonEqual()
2932 if (isAddOfNonZero(V1, V2, Depth, Q) || isAddOfNonZero(V2, V1, Depth, Q)) in isKnownNonEqual()
2935 if (isNonEqualMul(V1, V2, Depth, Q) || isNonEqualMul(V2, V1, Depth, Q)) in isKnownNonEqual()
2938 if (isNonEqualShl(V1, V2, Depth, Q) || isNonEqualShl(V2, V1, Depth, Q)) in isKnownNonEqual()
2944 KnownBits Known1 = computeKnownBits(V1, Depth, Q); in isKnownNonEqual()
2945 KnownBits Known2 = computeKnownBits(V2, Depth, Q); in isKnownNonEqual()
2963 bool MaskedValueIsZero(const Value *V, const APInt &Mask, unsigned Depth, in MaskedValueIsZero() argument
2966 computeKnownBits(V, Known, Depth, Q); in MaskedValueIsZero()
3048 unsigned Depth, const Query &Q);
3051 unsigned Depth, const Query &Q) { in ComputeNumSignBits() argument
3052 unsigned Result = ComputeNumSignBitsImpl(V, DemandedElts, Depth, Q); in ComputeNumSignBits()
3066 unsigned Depth, const Query &Q) { in ComputeNumSignBitsImpl() argument
3075 assert(Depth <= MaxAnalysisRecursionDepth && "Limit Search Depth"); in ComputeNumSignBitsImpl()
3102 if (Depth == MaxAnalysisRecursionDepth) in ComputeNumSignBitsImpl()
3110 return ComputeNumSignBits(U->getOperand(0), Depth + 1, Q) + Tmp; in ComputeNumSignBitsImpl()
3122 unsigned NumBits = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3131 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3162 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3178 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3190 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3192 Tmp2 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q); in ComputeNumSignBitsImpl()
3208 Tmp = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q); in ComputeNumSignBitsImpl()
3210 Tmp2 = ComputeNumSignBits(U->getOperand(2), Depth + 1, Q); in ComputeNumSignBitsImpl()
3217 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3224 computeKnownBits(U->getOperand(0), Known, Depth + 1, Q); in ComputeNumSignBitsImpl()
3237 Tmp2 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q); in ComputeNumSignBitsImpl()
3242 Tmp2 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q); in ComputeNumSignBitsImpl()
3249 computeKnownBits(U->getOperand(1), Known, Depth + 1, Q); in ComputeNumSignBitsImpl()
3266 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3273 unsigned SignBitsOp0 = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3275 unsigned SignBitsOp1 = ComputeNumSignBits(U->getOperand(1), Depth + 1, Q); in ComputeNumSignBitsImpl()
3298 Tmp, ComputeNumSignBits(PN->getIncomingValue(i), Depth + 1, RecQ)); in ComputeNumSignBitsImpl()
3313 return ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3331 Tmp = ComputeNumSignBits(LHS, DemandedLHS, Depth + 1, Q); in ComputeNumSignBitsImpl()
3339 Tmp2 = ComputeNumSignBits(RHS, DemandedRHS, Depth + 1, Q); in ComputeNumSignBitsImpl()
3354 Tmp = ComputeNumSignBits(U->getOperand(0), Depth + 1, Q); in ComputeNumSignBitsImpl()
3381 computeKnownBits(V, DemandedElts, Known, Depth, Q); in ComputeNumSignBitsImpl()
3499 unsigned Depth) { in CannotBeNegativeZero() argument
3503 if (Depth == MaxAnalysisRecursionDepth) in CannotBeNegativeZero()
3526 return CannotBeNegativeZero(Call->getArgOperand(0), TLI, Depth + 1); in CannotBeNegativeZero()
3531 return CannotBeNegativeZero(Call->getArgOperand(0), TLI, Depth + 1); in CannotBeNegativeZero()
3554 unsigned Depth) { in cannotBeOrderedLessThanZeroImpl() argument
3583 if (Depth == MaxAnalysisRecursionDepth) in cannotBeOrderedLessThanZeroImpl()
3604 Depth + 1) && in cannotBeOrderedLessThanZeroImpl()
3606 /*SignBitOnly*/ true, Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3617 Depth + 1) && in cannotBeOrderedLessThanZeroImpl()
3619 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3622 Depth + 1) && in cannotBeOrderedLessThanZeroImpl()
3624 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3629 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3635 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3657 cannotBeOrderedLessThanZeroImpl(V, TLI, false, Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3667 Depth + 1) || in cannotBeOrderedLessThanZeroImpl()
3669 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3673 Depth + 1) && in cannotBeOrderedLessThanZeroImpl()
3675 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3708 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3716 Depth + 1); in cannotBeOrderedLessThanZeroImpl()
3733 unsigned Depth) { in isKnownNeverInfinity() argument
3745 if (Depth == MaxAnalysisRecursionDepth) in isKnownNeverInfinity()
3751 return isKnownNeverInfinity(Inst->getOperand(1), TLI, Depth + 1) && in isKnownNeverInfinity()
3752 isKnownNeverInfinity(Inst->getOperand(2), TLI, Depth + 1); in isKnownNeverInfinity()
3797 unsigned Depth) { in isKnownNeverNaN() argument
3809 if (Depth == MaxAnalysisRecursionDepth) in isKnownNeverNaN()
3817 return isKnownNeverNaN(Inst->getOperand(0), TLI, Depth + 1) && in isKnownNeverNaN()
3818 isKnownNeverNaN(Inst->getOperand(1), TLI, Depth + 1) && in isKnownNeverNaN()
3819 (isKnownNeverInfinity(Inst->getOperand(0), TLI, Depth + 1) || in isKnownNeverNaN()
3820 isKnownNeverInfinity(Inst->getOperand(1), TLI, Depth + 1)); in isKnownNeverNaN()
3825 return isKnownNeverNaN(Inst->getOperand(0), TLI, Depth + 1) && in isKnownNeverNaN()
3826 isKnownNeverInfinity(Inst->getOperand(0), TLI, Depth + 1) && in isKnownNeverNaN()
3827 isKnownNeverNaN(Inst->getOperand(1), TLI, Depth + 1) && in isKnownNeverNaN()
3828 isKnownNeverInfinity(Inst->getOperand(1), TLI, Depth + 1); in isKnownNeverNaN()
3836 return isKnownNeverNaN(Inst->getOperand(1), TLI, Depth + 1) && in isKnownNeverNaN()
3837 isKnownNeverNaN(Inst->getOperand(2), TLI, Depth + 1); in isKnownNeverNaN()
3844 return isKnownNeverNaN(Inst->getOperand(0), TLI, Depth + 1); in isKnownNeverNaN()
3864 return isKnownNeverNaN(II->getArgOperand(0), TLI, Depth + 1); in isKnownNeverNaN()
3866 return isKnownNeverNaN(II->getArgOperand(0), TLI, Depth + 1) && in isKnownNeverNaN()
3871 return isKnownNeverNaN(II->getArgOperand(0), TLI, Depth + 1) || in isKnownNeverNaN()
3872 isKnownNeverNaN(II->getArgOperand(1), TLI, Depth + 1); in isKnownNeverNaN()
4832 const Value *V, bool ForSigned, const DataLayout &DL, unsigned Depth, in computeConstantRangeIncludingKnownBits() argument
4836 V, DL, Depth, AC, CxtI, DT, ORE, UseInstrInfo); in computeConstantRangeIncludingKnownBits()
5210 const Value *V, unsigned Depth) { in directlyImpliesPoison() argument
5215 if (Depth >= MaxDepth) in directlyImpliesPoison()
5221 return directlyImpliesPoison(ValAssumedPoison, Op, Depth + 1); in directlyImpliesPoison()
5227 Depth + 1); in directlyImpliesPoison()
5241 unsigned Depth) { in impliesPoison() argument
5249 if (Depth >= MaxDepth) in impliesPoison()
5255 return impliesPoison(Op, V, Depth + 1); in impliesPoison()
5272 unsigned Depth, bool PoisonOnly) { in isGuaranteedNotToBeUndefOrPoison() argument
5273 if (Depth >= MaxAnalysisRecursionDepth) in isGuaranteedNotToBeUndefOrPoison()
5312 return isGuaranteedNotToBeUndefOrPoison(V, AC, CtxI, DT, Depth + 1, in isGuaranteedNotToBeUndefOrPoison()
5333 DT, Depth + 1, PoisonOnly)) { in isGuaranteedNotToBeUndefOrPoison()
5402 unsigned Depth) { in isGuaranteedNotToBeUndefOrPoison() argument
5403 return ::isGuaranteedNotToBeUndefOrPoison(V, AC, CtxI, DT, Depth, false); in isGuaranteedNotToBeUndefOrPoison()
5408 const DominatorTree *DT, unsigned Depth) { in isGuaranteedNotToBePoison() argument
5409 return ::isGuaranteedNotToBeUndefOrPoison(V, AC, CtxI, DT, Depth, true); in isGuaranteedNotToBePoison()
5859 unsigned Depth) { in matchMinMaxOfMinMax() argument
5864 SelectPatternResult L = matchSelectPattern(TVal, A, B, nullptr, Depth + 1); in matchMinMaxOfMinMax()
5869 SelectPatternResult R = matchSelectPattern(FVal, C, D, nullptr, Depth + 1); in matchMinMaxOfMinMax()
5969 unsigned Depth) { in matchMinMax() argument
5978 SPR = matchMinMaxOfMinMax(Pred, CmpLHS, CmpRHS, TrueVal, FalseVal, Depth); in matchMinMax()
6060 unsigned Depth) { in matchSelectPattern() argument
6225 return matchMinMax(Pred, CmpLHS, CmpRHS, TrueVal, FalseVal, LHS, RHS, Depth); in matchSelectPattern()
6347 unsigned Depth) { in matchSelectPattern() argument
6348 if (Depth >= MaxAnalysisRecursionDepth) in matchSelectPattern()
6361 CastOp, Depth); in matchSelectPattern()
6366 Instruction::CastOps *CastOp, unsigned Depth) { in matchDecomposedSelectPattern() argument
6387 LHS, RHS, Depth); in matchDecomposedSelectPattern()
6396 LHS, RHS, Depth); in matchDecomposedSelectPattern()
6400 LHS, RHS, Depth); in matchDecomposedSelectPattern()
6555 unsigned Depth) { in isTruePredicate() argument
6591 computeKnownBits(X, Known, DL, Depth + 1, /*AC*/ nullptr, in isTruePredicate()
6615 const DataLayout &DL, unsigned Depth) { in isImpliedCondOperands() argument
6622 if (isTruePredicate(CmpInst::ICMP_SLE, BLHS, ALHS, DL, Depth) && in isImpliedCondOperands()
6623 isTruePredicate(CmpInst::ICMP_SLE, ARHS, BRHS, DL, Depth)) in isImpliedCondOperands()
6629 if (isTruePredicate(CmpInst::ICMP_ULE, BLHS, ALHS, DL, Depth) && in isImpliedCondOperands()
6630 isTruePredicate(CmpInst::ICMP_ULE, ARHS, BRHS, DL, Depth)) in isImpliedCondOperands()
6689 unsigned Depth) { in isImpliedCondICmps() argument
6716 return isImpliedCondOperands(APred, ALHS, ARHS, BLHS, BRHS, DL, Depth); in isImpliedCondICmps()
6726 const DataLayout &DL, bool LHSIsTrue, unsigned Depth) { in isImpliedCondAndOr() argument
6733 assert(Depth <= MaxAnalysisRecursionDepth && "Hit recursion limit"); in isImpliedCondAndOr()
6743 ALHS, RHSPred, RHSOp0, RHSOp1, DL, LHSIsTrue, Depth + 1)) in isImpliedCondAndOr()
6746 ARHS, RHSPred, RHSOp0, RHSOp1, DL, LHSIsTrue, Depth + 1)) in isImpliedCondAndOr()
6756 const DataLayout &DL, bool LHSIsTrue, unsigned Depth) { in isImpliedCondition() argument
6758 if (Depth == MaxAnalysisRecursionDepth) in isImpliedCondition()
6773 Depth); in isImpliedCondition()
6783 Depth); in isImpliedCondition()
6790 unsigned Depth) { in isImpliedCondition() argument
6798 LHSIsTrue, Depth); in isImpliedCondition()
6800 if (Depth == MaxAnalysisRecursionDepth) in isImpliedCondition()
6808 isImpliedCondition(LHS, RHS1, DL, LHSIsTrue, Depth + 1)) in isImpliedCondition()
6812 isImpliedCondition(LHS, RHS2, DL, LHSIsTrue, Depth + 1)) in isImpliedCondition()
6818 isImpliedCondition(LHS, RHS1, DL, LHSIsTrue, Depth + 1)) in isImpliedCondition()
6822 isImpliedCondition(LHS, RHS2, DL, LHSIsTrue, Depth + 1)) in isImpliedCondition()
7224 unsigned Depth) { in computeConstantRange() argument
7227 if (Depth == MaxAnalysisRecursionDepth) in computeConstantRange()
7274 UseInstrInfo, AC, I, DT, Depth + 1); in computeConstantRange()