RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v5]

fabioromano1 duke at openjdk.org
Tue Sep 3 16:53:19 UTC 2024


On Tue, 3 Sep 2024 16:29:10 GMT, Sergey Kuksenko <skuksenko at openjdk.org> wrote:

>>> It would be nice to see some benchmarks where it gives performance benefits.
>> 
>> @kuksenko Try to run the benchmark of the `BigInteger`'s square root, maybe there the benefits are more visibles...
>
>> > It would be nice to see some benchmarks where it gives performance benefits.
>> 
>> @kuksenko Try to run the benchmark of the `BigInteger`'s square root, maybe there the benefits are more visible...
> 
> "maybe"????
> So, you don't have proof that this PR gives any performance benefits.
> I don't think we have to make an optimization for the sake of optimizations.

@kuksenko It's not only for the sake of optimization, but to make the code more clear and consistent with the implementation of `BigInteger.shiftLeft()`.

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

PR Comment: https://git.openjdk.org/jdk/pull/20008#issuecomment-2326999188


More information about the core-libs-dev mailing list