JMH 1.37

Aleksey Shipilev shipilev at amazon.de
Thu Aug 3 14:17:07 UTC 2023


Hi,

JMH 1.37 is released and available at Maven Central.

This is the feature release and it contains the following changes.

Potentially breaking changes:

  *) "Secondary" results, overwhelmingly those coming from profilers, no longer have the Unicode dot 
prefix. This simplifies dealing with metrics in Java API, as well as in hand-parsing code. 
Unfortunately, this can break downstream users who would need to drop the dot from their metrics 
accessors as well. Users who store the secondary results in databases might need to strip the dot 
from the recorded results. This would hopefully be a one-time mechanical action.
   7903508: JMH: Remove the Unicode dot prefix from secondary results

   *) As part of Virtual Threads support, -Djmh.executor accepts new set of executor options, while 
rejecting now unsupported ones. We studied the commonly used executor types in the wild, and these 
types are now available: PLATFORM, VIRTUAL, FJP, CUSTOM. If you use any other executor type, the run 
would fail.
   7903486: JMH: Revisit available jmh.executor options

  *) Apache Math dependency was bumped to 3.6.1. This should not affect the current Maven/Gradle 
driven workflows, which would pull the new dependency automatically. Custom build scripts might need 
adjustment.
   7903392: Update to commons-math3 3.6.1 [contributed by Thomas Traude]

Major improvements:

  *) Virtual Threads support and bugfixes. -Djmh.executor=VIRTUAL runs benchmarks in virtual 
threads. There were many infrastructural changes to support these special executors. While current 
infrastructure looks stable in test, exercise caution when trusting the results, and submit bug 
reports if you stumble into new bugs.
   7903464: JMH: Add virtual threads executor [contributed by Sergey Kuksenko]
   7903476: JMH: Threading model should not assume stable threads
   7903498: JMH: Reset worker interrupt status after iteration
   7903492: JMH: Infrastructure code should yield occasionally for virtual executor to make progress
   7903490: JMH: The interrupt to time-outing benchmark can be delivered to worker data barrier

  *) Profiler improvements: new profilers, reliability and accuracy fixes in a few other profilers, 
making sure the profilers do not regress.
   7903455: JMH: Add "mempool" profiler [contributed by Eric Caspole]
   7903450: JMH: Improve -prof perfnorm accuracy with robust estimations
   7903461: JMH: perfasm profiler misses some jump edges
   7903413: JMH: Safepoint profiler should parse JDK 13+ -Xlog:safepoint
   7903484: JMH: Use ThreadMXBean.getTotalThreadAllocatedBytes for -prof gc
   7903487: JMH: Make sure JMH profilers work on all tested configurations

Minor improvements:

  *) New system property to control the compiler hints: -Djmh.compilerhints.mode, useful when JMH 
auto-detection fails to discover the JVM actually supports them. Acceptable values are: FORCE_ON, 
FORCE_OFF, AUTO_ON, AUTO_OFF.
   7903448: JMH: Override the use of compiler hints using a system property [contributed by Gilles 
Duboscq]

  *) -h  should be printed to a proper stream now:
   7903439: JMH: Print help to stdout instead of stderr [contributed by Seeta Ramayya]

Internal improvements, likely invisible to users:

  *) Various JMH Core Benchmarks additions:
   7903510: JMH: Add core performance checking tests
   7903511: JMH: Add score stability performance tests
   7903422: JMH: Add round-trip benchmarks to core tests

  *) Code cleanups:
   7903478: JMH: Use different padding names for B1 and B3 classes to avoid "hiding fields with same 
name" warnings [contributed by Vladimir Sitnikov]
   7903451: JMH: Refactor internal Optional usages [contributed by Andrei Rybak]


-- 
Thanks,
-Aleksey



Amazon Development Center Germany GmbH
Krausenstr. 38
10117 Berlin
Geschaeftsfuehrung: Christian Schlaeger, Jonathan Weiss
Eingetragen am Amtsgericht Charlottenburg unter HRB 149173 B
Sitz: Berlin
Ust-ID: DE 289 237 879




More information about the jmh-dev mailing list