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

fabioromano1 duke at openjdk.org
Mon Sep 2 16:23:19 UTC 2024


On Mon, 2 Sep 2024 16:04:14 GMT, Raffaello Giulietti <rgiulietti at openjdk.org> wrote:

> * I wonder if `MutableBigIntegerBox` can be reduced to just a set of accessors for the `MutableBigInteger` fields. Also, I guess that the benchmarks can be written to use the public class `BigInteger` to avoid having two copies of `MutableBigIntegerBox`.

@rgiulietti The trouble is that the method to test is `MBI.leftShift()`, and `BigInteger.shiftLeft()` has its own implementation that does not use `MBI.leftShift()`, so i cannot see how this can be done.

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

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


More information about the core-libs-dev mailing list