Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.

Port fix for dotnet/runtime#32059 to release/3.1 (JIT: make sure to set compLongUsed during struct promotion) #28024

Merged

Conversation

AndyAyersMS
Copy link
Member

If we're promoting a long field, make sure compLongUsed gets set.
Otherwise we may fail to properly decompose a long later on, leading
to access violations in the jit.

See dotnet/runtime#32059 for the original bug report, and
dotnet/runtime#32702 for the fix in 5.0.

Customer Impact

Unexpected and hard to diagnose crash in the jit. No easy workaround.

Regression?

Yes, introduced during the development 3.0 cycle. 2.x behaves correctly.

Testing

Verified the user's test case now passes; no diffs seen in any existing
framework or test code.

Risk

Low: fix is surgical and enables existing long operand handling in
the jit in one case that can be overlooked. Only impacts x86 and arm
codegen. Problematic IL patterns may not be reachable from C#.

If we're promoting a long field, make sure `compLongUsed` gets set.
Otherwise we may fail to properly decompose a long later on, leading
to access violations in the jit.

See dotnet/runtime#32059 for the original bug report, and
dotnet/runtime#32702 for the fix in 5.0.

## Customer Impact
Unexpected and hard to diagnose crash in the jit. No easy workaround.

## Regression?
Yes, introduced during the development 3.0 cycle. 2.x behaves correctly.

## Testing
Verified the user's test case now passes; no diffs seen in any existing
framework or test code.

## Risk
**Low**: fix is surgical and enables existing long operand handling in
the jit in one case that can be overlooked. Only impacts x86 and arm
codegen. Problematic IL patterns may not be reachable from C#.
@jeffschwMSFT jeffschwMSFT added the Servicing-consider Issue for next servicing release review label Feb 24, 2020
@jeffschwMSFT jeffschwMSFT added this to the 3.1.x milestone Feb 24, 2020
@jeffschwMSFT
Copy link
Member

Approved, will seek approval for April release

@AndyAyersMS
Copy link
Member Author

cc @BruceForstall

@AndyAyersMS
Copy link
Member Author

Two tests failed -- one timed out, the other got some Linux TLS error; both are unrelated.

@leecow leecow added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Feb 25, 2020
@leecow leecow modified the milestones: 3.1.x, 3.1.4 Feb 25, 2020
@danmoseley danmoseley changed the title Port fix for dotnet/runtime#32059 to release/3.1 Port fix for dotnet/runtime#32059 to release/3.1 (JIT: make sure to set compLongUsed during struct promotion) Mar 24, 2020
@Anipik Anipik merged commit f5d8d52 into dotnet:release/3.1 Mar 25, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Servicing-approved Approved for servicing release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants