AdoptOpenJDK / jitwatch

Log analyser / visualiser for Java HotSpot JIT compiler. Inspect inlining decisions, hot methods, bytecode, and assembly. View results in the JavaFX user interface.
Other
3.06k stars 437 forks source link

VM Version detection broken for JDK8 #303

Closed chriswhocodes closed 5 years ago

chriswhocodes commented 5 years ago
<vm_version>
<name>
Java HotSpot(TM) 64-Bit Server VM
</name>
<release>
25.172-b11
</release>
<info>
Java HotSpot(TM) 64-Bit Server VM (25.172-b11) for linux-amd64 JRE (1.8.0_172-b11), built on Mar 28 2018 21:44:09 by &quot;java_re&quot; with gcc 4.3.0 20080428 (Red Hat 4.3.0-8)
</info>
</vm_version>

Changes made to detect recent (JDK11+) JDKs broke detection of JDK8 version strings where the release tag only contains the HotSpot version.

Can try parsing version from the info tag or better, just make the XML parser more resilient to the differing LogCompilation format between JDK versions.

This bug breaks detection of eliminated allocs and locks on JDK8 logs.

TODO: Unit tests to prevent this regression creeping back in.

chriswhocodes commented 5 years ago

Fixed in https://github.com/AdoptOpenJDK/jitwatch/commit/2175016a037f26ae0966a50b68229bb8f8f5bb9c