- Notifications
You must be signed in to change notification settings - Fork5.2k
[release/9.0-staging] JIT: avoid fp divide by zero in profile synthesis#113418
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
[release/9.0-staging] JIT: avoid fp divide by zero in profile synthesis#113418
Uh oh!
There was an error while loading.Please reload this page.
Conversation
This can trip up users that have enabled floating point exceptions.While we don't generally support changing the exception modes we alsocan easily avoid dividing by zero here.Addresses#113369
Tagging subscribers to this area:@JulieLeeMSFT,@jakobbotsch |
AndyAyersMS commentedMar 12, 2025
@jeffschwMSFT@JulieLeeMSFT FYI cc @dotnet/jit-contrib |
jeffschwMSFT left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
lgtm. we will take for consideration in 9.0.x
c8613e5 intorelease/9.0-stagingUh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Backport of#113396 to release/9.0-staging
/cc@AndyAyersMS
Customer Impact
Unexpected floating-point divide by zero exception. While we generally don't support running managed code with FP exceptions enabled, we also should not be generating such exceptions needlessly.
There is precedent for us back porting this kind of change, see eg:#76334
Regression
.NET 9 added a fair amount of FP processing to the JIT that wasn't there in .NET 8.
Testing
Verified the JIT will no longer cause FP exception from this computation.
Risk
Low, no diffs in SPMI.