-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Corrupt data in struct passed to method via reflection on Unix #6834
Comments
@stephentoub smells like ABI issue. this is on x64? |
Let me dig into that. |
Yup |
It is really a bug in copying float args to the transition frame in the runtime. It happens when a struct uses two xmm registers. The offset to the next floating point register in the transition frame is shifted by 8 instead of by 16. I have fixed the same issue in the runtime for passing floating point arguments about a year ago, but obviously haven't realized that we have it at this other place. |
Thanks, @janvorli. |
Fixed by dotnet/coreclr#7716 |
Repro:
On CentOS and Ubuntu, this outputs various forms of:
with the reflection-based call getting garbage for two of the floats in the struct.
I got the above repro using the 1.0.1 release, but I started looking into it because of a CI failure in a new test I was adding on top of the latest coreclr pulled into corefx. (The issue that was happening in CI was only happening on CentOS for some reason, not on Ubuntu or OSX. I've not tried the above repro on OSX.)
The text was updated successfully, but these errors were encountered: