Skip to content

Commit 71e2552

Browse files
committed
Rangeanalysis: Use SsaReadPositionBlock.getAnSsaRead.
1 parent 27e6173 commit 71e2552

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

shared/rangeanalysis/codeql/rangeanalysis/ModulusAnalysis.qll

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,8 +254,7 @@ module ModulusAnalysis<
254254
or
255255
exists(Sem::SsaVariable v, SsaReadPositionBlock bb |
256256
ssaModulus(v, bb, b, val, mod) and
257-
e = v.getAUse() and
258-
bb.getBlock() = e.getBasicBlock()
257+
bb.getAnSsaRead(v) = e
259258
)
260259
or
261260
exists(Sem::Expr mid, int val0, int delta |

shared/rangeanalysis/codeql/rangeanalysis/RangeAnalysis.qll

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1167,8 +1167,7 @@ module RangeStage<
11671167
or
11681168
exists(Sem::SsaVariable v, SsaReadPositionBlock bb |
11691169
boundedSsa(v, b, delta, bb, upper, fromBackEdge, origdelta, reason) and
1170-
e = v.getAUse() and
1171-
bb.getBlock() = e.getBasicBlock()
1170+
bb.getAnSsaRead(v) = e
11721171
)
11731172
or
11741173
exists(Sem::Expr mid, D::Delta d1, D::Delta d2 |

0 commit comments

Comments
 (0)