On Sun, 7 Dec 2025 00:22:14 GMT, Jamil Nimeh <[email protected]> wrote:
>> test/micro/org/openjdk/bench/javax/crypto/full/KEMBench.java line 120:
>>
>>> 118:
>>> 119: public static class MLKEM extends KEMBench {
>>> 120: @Param({"ML-KEM-512", "ML-KEM-768", "ML-KEM-1024" })
>>
>> Not a JMH expert, but what is the difference between these parameters and
>> the ones on line 48? It looks like a duplicate test to me.
>
> It turns out this is a mistake. By having both this line and 48 with the
> same algorithm names, the benchmark runs them twice. Our benchmarks tend to
> be organized either with the main class as a baseline benchmark with
> subclasses for all other types, or an abstract base class with an empty
> @param tag and subclasses for each actual benchmark.
> `KeyAgreementBench.java` is done that way, and I personally like that
> approach better and changed this class to follow that model. Either way is
> just fine though. The important thing is that if you have parameters in the
> parent class, it should not match any parameter sets in the child classes or
> you just end up running the same benchmark twice.
Thanks for fixing these comments on KEMBench. @haimaychao you can resolve this
and the other 2 KEMBench related conversations now.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27614#discussion_r2599129398