JDK-8255368 : Math.exp() gives wrong result for large values on x86 32-bit platforms
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 11,15,16
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • CPU: x86
  • Submitted: 2020-10-23
  • Updated: 2024-12-20
  • Resolved: 2020-11-18
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11 JDK 16
11.0.11Fixed 16 b25Fixed
Related Reports
Duplicate :  
Relates :  
Description
exp(10000) give result as 0 instead of positive infinity on x86 32-bit platforms.
This is a bug in the 32-bit intrinsic.

Comments
[~aleonard] I've sponsored the OpenJDK 11u push for you.
24-02-2021

Fix Request Sponsored fix request comment on behalf of Andreas Ahlenstorf <andreas@ahlenstorf.ch>. Backporting this patch fixes a problem with Math.exp() giving wrong results for very large numbers on x86 (32 bit). The patch was directly exported from openjdk/jdk and applies cleanly to 11u. Running tier1 tests on Windows did not yield additional test failures and the test included in the patch passes, too. The patch corrects the x86 intrinsic of Math.exp() and should therefore have a small impact.
23-02-2021

Changeset: c0892148 Author: Xubo Zhang <xubo.zhang@intel.com> Committer: Sandhya Viswanathan <sviswanathan@openjdk.org> Date: 2020-11-18 04:49:15 +0000 URL: https://github.com/openjdk/jdk/commit/c0892148
18-11-2020

Great, thanks! Assigning this to you for now.
29-10-2020

[~thartmann] Yes, Xubo Zhang from Intel has a fix and will submit a pull request on this.
28-10-2020

[~sviswanathan] do you intent to work on this or should we assign to someone else? Did you investigate the root cause yet? Thanks.
28-10-2020

ILW = Incorrect execution of compiled code, Math.exp on 32-bit with large value, disable Math.exp intrinsic = HLM = P3
26-10-2020