RFR: 8367603: Optimize exact division in BigDecimal [v21]

Raffaello Giulietti rgiulietti at openjdk.org
Mon Sep 29 14:45:20 UTC 2025


On Mon, 29 Sep 2025 14:10:39 GMT, fabioromano1 <duke at openjdk.org> wrote:

>> A formula to lower the overestimate for the precision of an exact quotient, without introducing too expensive operations of division on numerator and denominator.
>
> fabioromano1 has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Added tests for extreme scale cases

Also update copyright year and add the issue number 8367603 to the `@bug` L.26

test/jdk/java/math/BigDecimal/DivideTests.java line 426:

> 424:                 failures++;
> 425:                 System.err.println("Unexpected quotient from " + tc[0] + " / " + tc[1] +
> 426:                                    "; expected " + tc[3] + " got " + quotient);

Suggestion:

                                   "; expected " + tc[2] + " got " + quotient);

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

PR Review: https://git.openjdk.org/jdk/pull/27271#pullrequestreview-3280225431
PR Review Comment: https://git.openjdk.org/jdk/pull/27271#discussion_r2388238743


More information about the core-libs-dev mailing list