RFR: 8344144: AES/CBC slow at big payloads [v2]

Anthony Scarpino ascarpino at openjdk.org
Tue Nov 19 00:08:54 UTC 2024


On Fri, 15 Nov 2024 17:00:44 GMT, Artur Barashev <abarashev at openjdk.org> wrote:

>> I believe the original wording is correct: the more payload the intrinsic gets the better (eg. the intrinsic parallelizes decryption, at the cost of some initial setup. More payload amortizes the setup cost). But cannot be so large that the intrinsic locks up the VM (preventing GC), encrypting gigabytes.
>
> But it takes a few calls before hotspot switches to the intrinsic, so it can't be too large. I think we should include this logic explanation (the intrinsic parallelizes decryption) in the comment to make it clear what we are doing here.

Maybe focus that this is triggering the optimization and not about the data size.

// chunkSize is a multiple of block size and used to divide up
// input data to trigger the intrinsic.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/22086#discussion_r1847460687


More information about the security-dev mailing list