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: Home float parameters before integer parameters #96439

Merged
merged 2 commits into from
Jan 5, 2024

Conversation

jakobbotsch
Copy link
Member

Parameters that are going into float registers can come from integer
registers in the presence of struct promotion. We need to home those
before integer parameters or the source register could have been
overridden by the integer parameter homing logic.

Ideally it seems like the homing logic should be unified to handle all
parameters simultaneously, but this seems like a simple enough fix. I do
not think we have ABIs where we have the opposite kind constraint
(integer parameters coming from float registers).

Fix #96306

Parameters that are going into float registers can come from integer
registers in the presence of struct promotion. We need to home those
before integer parameters or the source register could have been
overridden by the integer parameter homing logic.

Ideally it seems like the homing logic should be unified to handle all
parameters simultaneously, but this seems like a simple enough fix. I do
not think we have ABIs where we have the opposite kind constraint
(integer parameters coming from float registers).

Fix dotnet#96306
@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 Jan 3, 2024
@ghost ghost assigned jakobbotsch Jan 3, 2024
@ghost
Copy link

ghost commented Jan 3, 2024

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

Issue Details

Parameters that are going into float registers can come from integer
registers in the presence of struct promotion. We need to home those
before integer parameters or the source register could have been
overridden by the integer parameter homing logic.

Ideally it seems like the homing logic should be unified to handle all
parameters simultaneously, but this seems like a simple enough fix. I do
not think we have ABIs where we have the opposite kind constraint
(integer parameters coming from float registers).

Fix #96306

Author: jakobbotsch
Assignees: -
Labels:

area-CodeGen-coreclr

Milestone: -

@jakobbotsch
Copy link
Member Author

/azp run runtime-coreclr jitstress, runtime-coreclr libraries-jitstress, runtime-coreclr outerloop, Fuzzlyn

Copy link

Azure Pipelines successfully started running 4 pipeline(s).

@jakobbotsch
Copy link
Member Author

/azp run runtime-coreclr libraries-jitstress

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@jakobbotsch jakobbotsch marked this pull request as ready for review January 4, 2024 20:10
@jakobbotsch
Copy link
Member Author

cc @dotnet/jit-contrib

Diffs in quite a number of contexts, as one would expect, with minor code size differences (on arm64 only, due to no longer being able to do ldp/stp optimization).

@jakobbotsch jakobbotsch merged commit 928ff30 into dotnet:main Jan 5, 2024
267 of 271 checks passed
@jakobbotsch jakobbotsch deleted the fix-96306 branch January 5, 2024 14:23
@github-actions github-actions bot locked and limited conversation to collaborators Feb 5, 2024
@jakobbotsch
Copy link
Member Author

/backport to release/8.0-staging

@github-actions github-actions bot unlocked this conversation Feb 21, 2024
Copy link
Contributor

Started backporting to release/8.0-staging: https://github.com/dotnet/runtime/actions/runs/7988447721

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 21, 2024
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.

Corrupted function parameter value in Release configuration (overwritten by the first argument value).
2 participants