RFR: 8269827: JMH tests for AES/GCM byte[] and bytebuffers [v2]
Weijun Wang
weijun at openjdk.java.net
Tue Jul 6 15:44:49 UTC 2021
On Fri, 2 Jul 2021 23:30:17 GMT, Anthony Scarpino <ascarpino at openjdk.org> wrote:
>> Hi,
>>
>> I need a review of these new jmh tests that run AES/GCM encryption and decryption using byte[], heap bytebuffers, and direct bytebuffers as input and output buffers for single and multi-part testing.
>>
>> thanks
>>
>> Tony
>
> Anthony Scarpino has updated the pull request incrementally with one additional commit since the last revision:
>
> merge AESGCMByteArray with existing AESGCMBench
test/micro/org/openjdk/bench/javax/crypto/full/AESGCMBench.java line 46:
> 44: private int keyLength;
> 45:
> 46: @Param({"" + 1024, "" + 1500, "" + 4096, "" + 16384})
Now that you don't calculate anymore, how about just string literals like `"1024"` etc?
test/micro/org/openjdk/bench/javax/crypto/full/AESGCMBench.java line 58:
> 56: SecretKeySpec ks;
> 57: GCMParameterSpec gcm_spec;
> 58: byte[] aad;
Not an expert on this, but why no more AAD?
test/micro/org/openjdk/bench/javax/crypto/full/AESGCMByteBuffer.java line 44:
> 42: * benchmark operation
> 43: */
> 44:
Do you want to create a "small" version?
-------------
PR: https://git.openjdk.java.net/jdk/pull/4672
More information about the security-dev
mailing list