RFR: 8356709: Avoid redundant String formatting in BigDecimal.valueOf(double) [v2]

Johannes Graham duke at openjdk.org
Tue May 13 13:03:42 UTC 2025


> Optimize `BigDecimal.valueOf(double)` by using `FormattedFPDecimal` instead of converting to decimal string and then parsing it. This results in an approximate 6x improvement for me.

Johannes Graham has updated the pull request incrementally with one additional commit since the last revision:

  fix code tag in javadoc

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/25173/files
  - new: https://git.openjdk.org/jdk/pull/25173/files/569a6dfc..ba8d3933

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=25173&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=25173&range=00-01

  Stats: 2 lines in 1 file changed: 0 ins; 0 del; 2 mod
  Patch: https://git.openjdk.org/jdk/pull/25173.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/25173/head:pull/25173

PR: https://git.openjdk.org/jdk/pull/25173


More information about the core-libs-dev mailing list