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

Properly handle byrefs in tailcall helper stubs #41815

Merged
merged 2 commits into from
Sep 4, 2020

Conversation

jakobbotsch
Copy link
Member

Switch to using ByReference instead of using stind.i/ldind.i and relying
on the JIT to report the locations being moved between.

Fixes #41555

cc @BruceForstall @jkotas

Switch to using ByReference instead of using stind.i/ldind.i and relying
on the JIT to report the locations being moved between.

Fixes dotnet#41555
@Dotnet-GitSync-Bot Dotnet-GitSync-Bot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Sep 3, 2020
@jakobbotsch
Copy link
Member Author

@BruceForstall assuming tests pass, can you check if this fixes #41555?

@BruceForstall
Copy link
Member

@BruceForstall assuming tests pass, can you check if this fixes #41555?

I was never able to reliably repro the problem, so I won't be able to "prove" the fix works that way. I looked at the generated code + GC info for the "Call" stub for the 41555 test case on Windows arm32, and it looks good to me: the byrefs I annotated in the bug as needing GC tracking are appropriately tracked.

If you're happy with this change as is, I'm inclined to trigger outerloop + gcstress0x3-gcstress0xc + gcstress-extra legs. That's expensive and time consuming, but it's the best way, IMO, to see that the issue doesn't repro in the CI where it was (somewhat) reliably repro'ing (and check for regressions).

Copy link
Member

@BruceForstall BruceForstall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM; thanks for the quick turnaround!

@jakobbotsch
Copy link
Member Author

I was never able to reliably repro the problem, so I won't be able to "prove" the fix works that way. I looked at the generated code + GC info for the "Call" stub for the 41555 test case on Windows arm32, and it looks good to me: the byrefs I annotated in the bug as needing GC tracking are appropriately tracked.

If you're happy with this change as is, I'm inclined to trigger outerloop + gcstress0x3-gcstress0xc + gcstress-extra legs. That's expensive and time consuming, but it's the best way, IMO, to see that the issue doesn't repro in the CI where it was (somewhat) reliably repro'ing (and check for regressions).

Thanks for checking! Triggering those legs sounds good to me.

@BruceForstall
Copy link
Member

outerloop failures are #41853, gcstress failures are a few timeouts (that's unfortunately common). The _il_dbgreference_i test did not fail on Linux/arm anywhere, which is good.

@BruceForstall BruceForstall merged commit 8ceca25 into dotnet:master Sep 4, 2020
@jakobbotsch jakobbotsch deleted the byref-arg-buffer branch September 4, 2020 10:17
@BruceForstall
Copy link
Member

/backport to release/5.0-rc2

@github-actions
Copy link
Contributor

github-actions bot commented Sep 4, 2020

Started backporting to release/5.0-rc2: https://github.com/dotnet/runtime/actions/runs/239756050

@ghost ghost locked as resolved and limited conversation to collaborators Dec 7, 2020
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.

[GCStress] JIT/Methodical/tailcall/_il_dbgreference_i Assert failure SanityCheck()
4 participants