JMH 1.6
Aleksey Shipilev
aleksey.shipilev at oracle.com
Fri Feb 13 22:45:07 UTC 2015
Hi,
JMH 1.6 is released and available at Maven Central (thanks to Evgeny,
as usual). This is a feature release, and it also includes a few
bugfixes and internal API changes:
* Windows "xperfasm" support! Works with xperf from Windows Performance
Toolkit. Similarly to Linux "perfasm", it requires the hsdis plugin,
which you will have to build yourselves. It also (apparently) requires
running as Administrator to gain the access to hardware counters.
Current implementation may be rough around the edges, so please try it
and contribute the patches for it back. Contributed by Vladimir Ozerov,
kudos!
https://bugs.openjdk.java.net/browse/CODETOOLS-7901293
* Stack profiler can now filter the packages from the tops of stack
traces. This is useful to collapse the stacks ending e.g. in
java.util.HashMap.get() down to the exact user method caller. Suggested
and contributed by Behrooz Nobakht, thanks!
https://bugs.openjdk.java.net/browse/CODETOOLS-7901292
* Bugfix: with "-foe true", the CLI runner printed the exception, but
never modified the exit code. This trips some scripts that look for
non-zero exit code on failure. Fixed:
https://bugs.openjdk.java.net/browse/CODETOOLS-7901297
* Continuing the saga on JMH footprint to enable much longer and/or
precise experiments, two changes are done to reduce the SampleBuffer
footprint for around 50x. SampleBuffer accumulates the results for
SampleTime runs, and therefore short iterations in SampleTime mode were
producing an immense amount of garbage. With these changes, we can run
tens of thousands of iterations without any glitch:
https://bugs.openjdk.java.net/browse/CODETOOLS-7901299
https://bugs.openjdk.java.net/browse/CODETOOLS-7901301
* Profiler {after|before}{Iteration|Trial} methods should not be called
in a random order. In this release we only guarantee some deterministic
order (that coincides with the profiler enumeration order). In future,
we will specify it more rigorously:
https://bugs.openjdk.java.net/browse/CODETOOLS-7901303
https://bugs.openjdk.java.net/browse/CODETOOLS-7901300
* JMHSample_10_ConstantFold sample was updated with the "final" case.
Compilers routinely optimize final fields (and sometimes they don't), so
be careful:
http://hg.openjdk.java.net/code-tools/jmh/rev/1bb680b3d89a
Enjoy!
-Aleksey.
More information about the jmh-dev
mailing list