RFR: 8310843: Reimplement ByteArray and ByteArrayLittleEndian with Unsafe [v10]
Glavo
duke at openjdk.org
Thu Jul 20 16:42:45 UTC 2023
On Thu, 20 Jul 2023 16:24:09 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
> Here's with the same parameters as the one you are using:
I don't understand why there is such a difference. I have replicated similar results on several other devices:
Apple M1:
Benchmark Mode Cnt Score Error Units
ByteArray.readByte thrpt 5 1418606.665 ± 2308.711 ops/ms
ByteArray.readByteFromBuffer thrpt 5 879084.678 ± 20981.303 ops/ms
ByteArray.readInt thrpt 5 1404164.063 ± 4845.412 ops/ms
ByteArray.readIntFromBuffer thrpt 5 829768.843 ± 8730.467 ops/ms
ByteArray.readLong thrpt 5 1400713.660 ± 1924.752 ops/ms
ByteArray.readLongFromBuffer thrpt 5 825721.508 ± 4146.961 ops/ms
Intel Celeron N5105:
Benchmark Mode Cnt Score Error Units
ByteArray.readByte thrpt 5 927248.807 ± 29630.442 ops/ms
ByteArray.readByteFromBuffer thrpt 5 448374.359 ± 3210.571 ops/ms
ByteArray.readInt thrpt 5 719143.935 ± 183584.747 ops/ms
ByteArray.readIntFromBuffer thrpt 5 398578.488 ± 100.058 ops/ms
ByteArray.readLong thrpt 5 742555.147 ± 13006.710 ops/ms
ByteArray.readLongFromBuffer thrpt 5 398771.660 ± 1673.524 ops/ms
AMD Ryzen 7 5800X:
Benchmark Mode Cnt Score Error Units
ByteArray.readByte thrpt 5 1784096.905 ± 47611.535 ops/ms
ByteArray.readByteFromBuffer thrpt 5 992974.747 ± 19389.011 ops/ms
ByteArray.readInt thrpt 5 1719368.129 ± 70606.284 ops/ms
ByteArray.readIntFromBuffer thrpt 5 919654.075 ± 9292.283 ops/ms
ByteArray.readLong thrpt 5 1719873.280 ± 18441.122 ops/ms
ByteArray.readLongFromBuffer thrpt 5 921992.992 ± 6439.747 ops/ms
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14636#discussion_r1269714639
More information about the core-libs-dev
mailing list