-
-
Notifications
You must be signed in to change notification settings - Fork 443
Troubleshooting
If you run JITWatch on a system with a different Locale to the one on which the logs were taken then you may find the different LogCompilation timestamp decimals are wrongly interpreted:
stamp="1,234" is interpreted as 1234 seconds and not the decimal 1 and 234/1000ths.
To work around this, start JITWatch with system properties that override the country and language to those of the system where the log was taken:
-Duser.country=DE -Duser.language=de
The HotSpot VM writes LogCompilation information to a temporary file per JIT compiler thread and these temporary files are combined into hotspot.log when the VM shuts down.
If you stop the VM with SIGQUIT (kill -9) the VM does not combine the logs. Stopping the program with a System.exit() or using a SIGTERM (kill) signal will ensure the logs are combined.
At this time, OpenJDK builds from AdoptOpenJDK do not include JavaFX libraries. As a workaround, you can pull OpenJDK builds from other sources that do include this. One suggestion is https://www.azul.com/downloads/zulu-community/. Note that this site contains builds both with and without JavaFX so make sure you choose "JDK FX" and not just "JDK".
The combination of both recommendations below turned JITWatch from unusable to awesome for one user's experience. Your mileage may vary but the tricks are worth noting.
If scrolling is painfully slow in TriView, particularly on an older system, try "-Dprism.order=sw" in JVM arguments.
If loading a log file of several hundred megabytes or more and using a larger heap size (e.g. 10G+), try "-XX:+UseG1GC" in JVM arguments
On Windows, there is no way on the command line to gracefully shutdown a JVM. A graceful shutdown is required for the JVM to fully flush the JIT logs for JITWatch to parse. The workaround is to ask the JVM to load an agent jar where the agent jar requests that the loading JVM execute a graceful shutdown. Two open source tools can assist here:
- A simple agent jar that requests a graceful shutdown (but you must write code to load it): https://github.com/everit-org/javaagent-shutdown
- Command line utility to find JVMs based on a partial-text search of the command line and load the preceding agent jar: https://github.com/JDASoftwareGroup/graceful-kill-java
- Currently works only with OpenJDK 8 (sorry). Pull requests welcome for later versions!
For large log files (e.g. 300MB+), JITWatch may fail to fully load the log file the first time. The symptom is that classes known to be JIT compiled are not listed as JIT compiled. The workaround is simply to hit Reset and Start. The second attempt will consistently load the entire log file.