-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Ssa: Deprecate the unused getALastRead predicate. #18729
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 20 out of 20 changed files in this pull request and generated no comments.
Tip: If you use Visual Studio Code, you can request a review from Copilot before you push from the "Source Control" tab. Learn more
@@ -292,7 +290,9 @@ | |||
|
|||
/** Same as `lastRefRedef`, but skips uncertain reads. */ | |||
pragma[nomagic] | |||
private predicate lastRefSkipUncertainReadsExt(DefinitionExt def, SsaInput::BasicBlock bb, int i) { | |||
deprecated private predicate lastRefSkipUncertainReadsExt( |
Check warning
Code scanning / CodeQL
Missing QLDoc for parameter Warning
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, one comment.
@@ -958,7 +960,7 @@ private module Cached { | |||
} | |||
|
|||
cached |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's OK to replace this with pragma[nomagic]
; I highly doubt anyone actually calls this.
@@ -407,7 +409,7 @@ private module Cached { | |||
* the end of the CFG scope, without passing through another non-pseudo read. | |||
*/ | |||
cached | |||
predicate lastRead(Definition def, VariableReadAccessCfgNode read) { | |||
deprecated predicate lastRead(Definition def, VariableReadAccessCfgNode read) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same.
The SSA predicate
getALastRead
is entirely unused. Presumably this was needed in the past for proper implementation ofout
andref
nodes in C#, but this is now handled via pseudo-reads.This PR deprecates all involved predicates (or deletes in the case of Rust). This means that the
ExitBasicBlock
in theInputSig
is effectively unused, so a second commit deletes that.