Fully featured low overhead profiler for Java EE and Java SE platforms.
Performance monitoring and profiling of Jenkins, TeamCity, Gradle, Maven, Ant, JUnit and TestNG.
Easy to use performance and memory profiler for .NET framework.

GC Pause Effects?

Moderators: Vladimir Kondratyev, Anton Katilin

GC Pause Effects?

Postby alecla » Tue Sep 24, 2019 5:46 pm

I noticed YourKit is tracking GC Pauses in the performance timeline. I'm curious what the effect of these pauses are on the different types of snapshots (tracing, sampling CPU time, sampling wall time)?

I would hope it's not influencing the captures for tracing and sampling CPU time but perhaps it is for sample wall time? Or is an GC pause excluded from wall time so that's accurate as well?
alecla
 
Posts: 2
Joined: Tue Sep 24, 2019 5:43 pm

Re: GC Pause Effects?

Postby Anton Katilin » Tue Sep 24, 2019 6:28 pm

GC pauses happen when the garbage collector decides they should happen. The profiler shows pause count and duration information as reported by the JVM.

GC pause time is not used for measured time correction.
Anton Katilin
 
Posts: 5826
Joined: Wed Aug 11, 2004 8:37 am

Re: GC Pause Effects?

Postby alecla » Tue Sep 24, 2019 7:03 pm

So to clarify the question if a thread is in method myMethod() that usually takes 25ms and there's a 2 second GC pause during the snapshot collection time YourKit will report a hotspot and 2025ms time in ALL tracing modes?
alecla
 
Posts: 2
Joined: Tue Sep 24, 2019 5:43 pm

Re: GC Pause Effects?

Postby Anton Katilin » Wed Sep 25, 2019 4:42 am

If the GC pause is stop-the-world and therefore stops the thread, then yes.
However, modern collectors (e.g. G1) designed to be "almost pauseless" will make GC pauses much shorter, and these 2 seconds from your example are likely impossible unless you have opted to use a throughput-oriented garbage collector instead where longer pauses are possible (and acceptable) but overall GC overhead is lower.
Anton Katilin
 
Posts: 5826
Joined: Wed Aug 11, 2004 8:37 am


Return to Java Profiler

Who is online

Users browsing this forum: No registered users and 21 guests

cron

YourKit uses cookies and other tracking technologies to improve your browsing experience on our website, to show you personalized content and targeted ads, to analyze our website traffic, and to understand where our visitors are coming from.

By browsing our website, you consent to our use of cookies and other tracking technologies in accordance with the Privacy Policy.