Skip to content
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

JIT: fix interaction of OSR and shadowed parameters #67884

Merged
merged 1 commit into from
Apr 12, 2022

Conversation

AndyAyersMS
Copy link
Member

If a Tier0 method has shadowed parameters, the patchpoint info it creates
must refer to the stack slots for the shadow copies. Otherwise any updates
made to the params by the Tier0 code will not be seen by the OSR method.

Fixes #67410.

If a Tier0 method has shadowed parameters, the patchpoint info it creates
must refer to the stack slots for the shadow copies. Otherwise any updates
made to the params by the Tier0 code will not be seen by the OSR method.

Fixes dotnet#67410.
@dotnet-issue-labeler dotnet-issue-labeler bot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Apr 12, 2022
@ghost ghost assigned AndyAyersMS Apr 12, 2022
@ghost
Copy link

ghost commented Apr 12, 2022

Tagging subscribers to this area: @JulieLeeMSFT
See info in area-owners.md if you want to be subscribed.

Issue Details

If a Tier0 method has shadowed parameters, the patchpoint info it creates
must refer to the stack slots for the shadow copies. Otherwise any updates
made to the params by the Tier0 code will not be seen by the OSR method.

Fixes #67410.

Author: AndyAyersMS
Assignees: -
Labels:

area-CodeGen-coreclr

Milestone: -

@AndyAyersMS
Copy link
Member Author

@EgorBo PTAL
cc @dotnet/jit-contrib

@AndyAyersMS
Copy link
Member Author

All the failures are in System.Text.RegularExpressions.Tests.RegexMatchTests.Match_InstanceMethods_DefaultTimeout_Throws -- see #67886.

@AndyAyersMS AndyAyersMS merged commit 04dea79 into dotnet:main Apr 12, 2022
AndyAyersMS added a commit to AndyAyersMS/runtime that referenced this pull request Apr 14, 2022
As a result of dotnet#67884, OSR compilations were looking at data in the
`gsShadowVarInfo` array in cases where it was not initialized.

Fix is to defer allocating the `gsShadowVarInfo` array until it's certain
it will be initialized.

Fixes dotnet#68003.
AndyAyersMS added a commit that referenced this pull request Apr 15, 2022
As a result of #67884, OSR compilations were looking at data in the
`gsShadowVarInfo` array in cases where it was not initialized.

Fix is to null out `gsShadowVarInfo` array if there are no shadowed params.

Fixes #68003.
@ghost ghost locked as resolved and limited conversation to collaborators May 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test failure DataContractSerializerTests.DCS_MyPersonSurrogate_Stress
2 participants