RFR: 8367603: Optimize exact division in BigDecimal [v22]
Joe Darcy
darcy at openjdk.org
Mon Oct 27 19:44:12 UTC 2025
On Mon, 29 Sep 2025 16:12:20 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 two additional commits since the last revision:
>
> - Simplification
> - Update DivideTests.java
src/java.base/share/classes/java/math/BigInteger.java line 2907:
> 2905: * Calculate bitlength of the magnitude of this {@code BigInteger}.
> 2906: */
> 2907: int magBitLength() {
Please add to the javadoc comment here "Package private method to ..." as done for other methods in BigInteger used elsewhere in the package.
(In some other classes in java.base, people will add `/* package */` or similar comments on the method declaration line to explicitly indicate the method is intended to have package access.)
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27271#discussion_r2466873127
More information about the core-libs-dev
mailing list