On Mon, 10 Jun 2024 17:25:21 GMT, Vladimir Kozlov <k...@openjdk.org> wrote:
>> This PR removes some unnecessary conversions between byte arrays and long >> arrays during SHA3 digest computations. > > src/java.base/share/classes/sun/security/provider/SHA3.java line 98: > >> 96: @IntrinsicCandidate >> 97: private void implCompress0(byte[] b, int ofs) { >> 98: b2lLittle(b, ofs, longBuf, 0, blockSize); > > What about BigEndian machines? According to the SHA3 algorithm specification, this byte array should be interpreted as a little endian long array. b2lLittle() does just that on both little and big endian machines. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/19632#discussion_r1633606439