Value returned by benchmark method.

Artem Barger artem at bargr.net
Tue Aug 9 13:33:24 UTC 2016


Hi,

Is there a way to enable printing out or showing the computation results
from the benchmarking method? For example:

@Benchmark
public double bechComputation(SomeState state) {
     return computeResult(state);
}

And assuming that based on state "computeResult" runs different algorithms,
therefore besides of getting performance wise results, it would be also
interesting to compare the actual results of the computation to
validate/compare the accuracy.

Is that possible to achieve it using current JMH version? Does it look
reasonable to ask for such feature?

Best regards,
                      Artem Barger.


More information about the jmh-dev mailing list