-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Remove unnecessary GcInfoEncoder::DoNotTrackInPartiallyInterruptible
#113078
Remove unnecessary GcInfoEncoder::DoNotTrackInPartiallyInterruptible
#113078
Conversation
This check always succeeds (tested with an assert otherwise on the first commit in this PR). |
GcInfoEncoder::DoNotTrackInPartiallyInterruptible
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch |
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 2 out of 2 changed files in this pull request and generated no comments.
cc @dotnet/jit-contrib PTAL @VSadov No diffs again. The JIT is already ensuring that the encoder does not see any "wrong" registers here, it seems. |
|
||
// tells whether a slot cannot contain an object reference | ||
// at call instruction or right after returning | ||
bool GcInfoEncoder::DoNotTrackInPartiallyInterruptible(GcSlotDesc &slotDesc) |
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 this was an optimization in the past to filter out volatile registers early.
It also claims to filter out things that cannot possibly contain a ref - but why would that even come as an input? The filtering probably did not help much in this regard.
Now that we record everything that is alive, the filtering is pointless indeed.
@@ -21,6 +21,7 @@ pr: | |||
# so that this build can block dependency auto-updates (this build is currently ignored) | |||
include: | |||
- src/coreclr/jit/* | |||
- src/coreclr/gcinfo/* |
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.
What are these changes for? (just curious)
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.
superpmi-asmdiffs was not running for this change, even though the gcinfoencoder is statically linked into the JIT and affects its compilation results. This change is ensuring that superpmi-asmdiffs runs even on gcinfoencoder changes (so that we can see diffs).
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!
Also it was a piece of code that needs to be maintained for every architecture/platform/ABI. Nice that it is gone. |
The check as it was used always returned false (verified that with an assert on the first commit). Instead trust the user of the encoder on what registers to report and not report. This unblocks custom calling conventions like in #112406 and with runtime async.