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

Unable to parse the log file created by java 11 #305

Closed ramkrish86 closed 5 years ago

ramkrish86 commented 5 years ago

I made the jitwatch to work with java11 and once I got the UI working, i tried loading a log file that is created out of running a microbenchmark with java11. But the UI says please enable the '-XX:+TraceClassLoading'. I have already enabled it but still does not seem to work.

The exact microbenchmark when ran with JDK8, I was able to open it and analyse it. Am I missing something here or is there any workaround for this? @chriswhocodes . Thanks in advance.

chriswhocodes commented 5 years ago

Hi @ramkrish86, JITWatch should work fine without -XX:+TraceClassLoading which was replaced in JDK9+ with unified logging. It's only really a shortcut to automatically pick up the classpath instead of having to set it up manually in the JITWatch config. I'll take a look at what's happening here.

chriswhocodes commented 5 years ago

Hi @ramkrish86 , I just tried running JITWatch using Azul's ZuluFX 11.0.3 (which includes JavaFX) and I ran the makeDemoLogFile.sh with and without -XX:+TraceClassLoading and both times JITWatch worked fine and did not show any messages about that switch.

I've checked the code and I can't see any places it complains about that switch. Can you confirm you're running the latest version of JITWatch please?

Could you paste a screenshot of the error message for me?

Thanks,

Chris

ramkrish86 commented 5 years ago

image @chriswhocodes - thanks for your reply. See the attached screenshot. With or without the -XX:+TraceClassLoading I get that error in the jitwatch. I downloaded the available latest zip file for the jitwatch. Is there any other latest version that I can make use of?

ramkrish86 commented 5 years ago

FYI - I am using jitwatch-run-1.3.0.jar that I built using 'https://jitpack.io'

chriswhocodes commented 5 years ago

Hi @ramkrish86 I'm afraid you're using an old version of JITWatch. Newer versions are JDK11+ compatible and don't have this restriction.

I've not heard of jitpack.io - the usual method of running JITWatch is to clone it from GitHub and build it with Maven.

I will look into ways of distributing JITWatch as an executable (uber)jar but I'll close this issue for now as the problem you're facing is not present in the HEAD revision. Cheers, Chris

ramkrish86 commented 5 years ago

Thanks @chriswhocodes . I will try to use the latest HEAD version to see if I can parse the java11 log file. Thanks for your time.