@@ -1563,7 +1563,6 @@ private QlBuiltins::BigInt getGuardedUpperBound(VariableAccess guardedAccess) {
15631563 )
15641564}
15651565
1566- cached
15671566private module SimpleRangeAnalysisCached {
15681567 /**
15691568 * Gets the lower bound of the expression.
@@ -1577,7 +1576,6 @@ private module SimpleRangeAnalysisCached {
15771576 *
15781577 * `lowerBound(expr.getFullyConverted())`
15791578 */
1580- cached
15811579 QlBuiltins:: BigInt lowerBound ( Expr expr ) {
15821580 // Combine the lower bounds returned by getTruncatedLowerBounds into a
15831581 // single minimum value.
@@ -1596,15 +1594,13 @@ private module SimpleRangeAnalysisCached {
15961594 *
15971595 * `upperBound(expr.getFullyConverted())`
15981596 */
1599- cached
16001597 QlBuiltins:: BigInt upperBound ( Expr expr ) {
16011598 // Combine the upper bounds returned by getTruncatedUpperBounds and
16021599 // getGuardedUpperBound into a single maximum value
16031600 result = min ( [ max ( getTruncatedUpperBounds ( expr ) ) , getGuardedUpperBound ( expr ) ] )
16041601 }
16051602
16061603 /** Holds if the upper bound of `expr` may have been widened. This means the upper bound is in practice likely to be overly wide. */
1607- cached
16081604 predicate upperBoundMayBeWidened ( Expr e ) {
16091605 isRecursiveExpr ( e ) and
16101606 // Widening is not a problem if the post-analysis in `getGuardedUpperBound` has overridden the widening.
@@ -1627,7 +1623,6 @@ private module SimpleRangeAnalysisCached {
16271623 * }
16281624 * }
16291625 */
1630- cached
16311626 predicate exprWithEmptyRange ( Expr expr ) {
16321627 analyzableExpr ( expr ) and
16331628 (
@@ -1638,13 +1633,11 @@ private module SimpleRangeAnalysisCached {
16381633 }
16391634
16401635 /** Holds if the definition might overflow negatively. */
1641- cached
16421636 predicate defMightOverflowNegatively ( RangeSsaDefinition def , StackVariable v ) {
16431637 getDefLowerBoundsImpl ( def , v ) < varMinVal ( v )
16441638 }
16451639
16461640 /** Holds if the definition might overflow positively. */
1647- cached
16481641 predicate defMightOverflowPositively ( RangeSsaDefinition def , StackVariable v ) {
16491642 getDefUpperBoundsImpl ( def , v ) > varMaxVal ( v )
16501643 }
@@ -1653,7 +1646,6 @@ private module SimpleRangeAnalysisCached {
16531646 * Holds if the definition might overflow (either positively or
16541647 * negatively).
16551648 */
1656- cached
16571649 predicate defMightOverflow ( RangeSsaDefinition def , StackVariable v ) {
16581650 defMightOverflowNegatively ( def , v ) or
16591651 defMightOverflowPositively ( def , v )
@@ -1678,7 +1670,6 @@ private module SimpleRangeAnalysisCached {
16781670 * does not consider the possibility that the expression might overflow
16791671 * due to a conversion.
16801672 */
1681- cached
16821673 predicate exprMightOverflowNegatively ( Expr expr ) {
16831674 getLowerBoundsImpl ( expr ) < exprMinVal ( expr )
16841675 or
@@ -1699,7 +1690,6 @@ private module SimpleRangeAnalysisCached {
16991690 * `(int16)(x+y)` might overflow due to the `(int16)` cast, rather than
17001691 * due to the addition.
17011692 */
1702- cached
17031693 predicate convertedExprMightOverflowNegatively ( Expr expr ) {
17041694 exprMightOverflowNegatively ( expr ) or
17051695 convertedExprMightOverflowNegatively ( expr .getConversion ( ) )
@@ -1710,7 +1700,6 @@ private module SimpleRangeAnalysisCached {
17101700 * does not consider the possibility that the expression might overflow
17111701 * due to a conversion.
17121702 */
1713- cached
17141703 predicate exprMightOverflowPositively ( Expr expr ) {
17151704 getUpperBoundsImpl ( expr ) > exprMaxVal ( expr )
17161705 or
@@ -1731,7 +1720,6 @@ private module SimpleRangeAnalysisCached {
17311720 * `(int16)(x+y)` might overflow due to the `(int16)` cast, rather than
17321721 * due to the addition.
17331722 */
1734- cached
17351723 predicate convertedExprMightOverflowPositively ( Expr expr ) {
17361724 exprMightOverflowPositively ( expr ) or
17371725 convertedExprMightOverflowPositively ( expr .getConversion ( ) )
@@ -1742,7 +1730,6 @@ private module SimpleRangeAnalysisCached {
17421730 * negatively). The possibility that the expression might overflow
17431731 * due to an implicit or explicit cast is also considered.
17441732 */
1745- cached
17461733 predicate convertedExprMightOverflow ( Expr expr ) {
17471734 convertedExprMightOverflowNegatively ( expr ) or
17481735 convertedExprMightOverflowPositively ( expr )
0 commit comments