RFR: JDK-8323186: A faster algorithm for MutablebigInteger.divWord(long, int) [v3]

fabioromano1 duke at openjdk.org
Mon Jan 22 16:03:31 UTC 2024


On Mon, 22 Jan 2024 15:38:08 GMT, Raffaello Giulietti <rgiulietti at openjdk.org> wrote:

>> fabioromano1 has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Removed trailing whitespaces
>
> Sure. But the purpose of a test is not much to check the _current_ code but to protect against erroneous changes in the future. Without a test, a later modification might introduce an undetected regression.

@rgiulietti By the way, the tests for correctness of `Long.divideUnsigned(long, long)` and `Long.remainderUnsigned(long, long)` simply check the consistency between their results and those of `BigInteger.divide(BigInteger)`, so those tests are implicitly tests also for `MutablebigInteger.divWord(long, int)`.

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

PR Comment: https://git.openjdk.org/jdk/pull/17291#issuecomment-1904311866


More information about the core-libs-dev mailing list