Summary
The JMH is a powerful harness and is truly capable of creating and running several types of microbenchmarks. The important point to remember is that JDK 9 is going to be the most powerful version of the famous virtual machine and will require the use of the most optimized code. microbenchmarks have been present in Java and other languages. They provide the time it needs to run a particular code as well as the throughput performance.
This information is useful in several instances, but it can simply present faulty information in the case of the compiler performing the optimizations, and eliminating the dead code, which it finds within the loops that are present in the created microbenchmark.
The JMH will now be included with the Java ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access