C++: Filter out lower bounds on overflowing exprs

Fixes performance issues where multiple lower bounds would be
computed for overflowing expressions
This commit is contained in:
Robert Marsh
2020-11-24 12:52:42 -08:00
parent 9b07782d19
commit 0cd6941a21

View File

@@ -625,7 +625,8 @@ private float getTruncatedLowerBounds(Expr expr) {
)
else result = newLB
else result = exprMinVal(expr)
)
) and
getUpperBoundsImpl(expr) <= exprMaxVal(expr)
or
// The expression might overflow and wrap. If so, the
// lower bound is exprMinVal.