-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Make FailFast a QCall #98908
Make FailFast a QCall #98908
Conversation
c535a1c
to
aed8fd4
Compare
@dotnet/dotnet-diag Could you please comment on impact of this change on Watson? |
I checked the reflection case and confirmed that the calculated return address is in the same location as before this change. |
@leculver @mikem8361 - I think you guys are in the best position to evaluate. |
It look like it should have any impact on Watson to me. |
src/coreclr/System.Private.CoreLib/src/System/Environment.CoreCLR.cs
Outdated
Show resolved
Hide resolved
src/coreclr/System.Private.CoreLib/src/System/Environment.CoreCLR.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: Jan Kotas <[email protected]>
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.
Thank you!
This has a similar structure to FailFast as converted in dotnet#98908. Contributes to dotnet#95695
* Convert GetCurrentMethod to QCALL This has a similar structure to FailFast as converted in #98908. Contributes to #95695 * Simplify code for QCALL Co-authored-by: Jan Kotas <[email protected]> --------- Co-authored-by: Jan Kotas <[email protected]>
I confirmed that the instruction pointer found by stack walking matched the IP found by the FCALL version (pointing to the return address of the function that called FailFast). I do not know if that is sufficient to preserve the "Watson bucketization" that the many comments around this code mention.
TODO:
retAdress
is the same after this change for direct calls toFailFast
. It is the return address in the calling function.CallDescrWorkerInternal
atCallDescrWorkerInternalReturnAddress
. Maybe that is not the best address for bucketization, but it's the same address as before.GenericFailFast
does a GCPROTECT and the QCALLS don't do anything that triggers a GC before callingGenericFailFast
, so are they needed?Contributes to #95695