mirror of
https://github.com/github/codeql.git
synced 2026-04-29 10:45:15 +02:00
C++: pragma[nomagic] in Overflow.qll
These two predicates were supposed to be fast but became slow after the recent inlining of `unresolve`.
This commit is contained in:
@@ -13,6 +13,7 @@ predicate guardedAbs(Operation e, Expr use) {
|
||||
}
|
||||
|
||||
/** is the size of this use guarded to be less than something? */
|
||||
pragma[nomagic]
|
||||
predicate guardedLesser(Operation e, Expr use) {
|
||||
exists(IfStmt c, RelationalOperation guard |
|
||||
use = guard.getLesserOperand().getAChild*() and
|
||||
@@ -33,6 +34,7 @@ predicate guardedLesser(Operation e, Expr use) {
|
||||
}
|
||||
|
||||
/** is the size of this use guarded to be greater than something? */
|
||||
pragma[nomagic]
|
||||
predicate guardedGreater(Operation e, Expr use) {
|
||||
exists(IfStmt c, RelationalOperation guard |
|
||||
use = guard.getGreaterOperand().getAChild*() and
|
||||
|
||||
Reference in New Issue
Block a user