java 1.7.0u4 GarbageCollectionNotificationInfo API (original) (raw)

John Cuthbertson john.cuthbertson at oracle.com
Fri Feb 1 14:17:50 PST 2013


Hi Taras,

I'm going to cc the serviceability alias. I think they might be best suited to answer some of your questions. I believe they own the API and the GC provides the data.

Answer 1: It should be milliseconds, but there was a bug (http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7087969) that is now fixed in hs24 and you could be running into that.

Answer 2: This sounds like a bug. Do you have a test case you can share?

Answer 3: I'll leave that to the serviceability guys.

Regards,

JohnC

On 1/28/2013 1:11 PM, Taras Tielkes wrote:

Hi, I'm playing around with the new(ish) GarbageCollectionNotificationInfo API. We're using ParNew+CMS in all our systems, and my first goal is a comparison between -XX:+PrintGCDetails -verbose:gc output and the actual data coming through the notification API. I'm using Java 1.7.0u6 for the experiments. So far, I have a number of questions: 1) duration times The javadoc for gcInfo.getDuration() describes the returned value as expressed in milliseconds. However, the values differ to the gc logs by several orders of magnitude. How are they calculated? On a 1-core Linux x64 VM, the values actually look like microseconds, but on a Win32 machines I still can't figure out any resemblance to gc log timings. Apart from the unit, what should the value represent? Real time or user time? 2) CMS events with cause "No GC" How exactly do the phases of CMS map to the notifications emitted for the CMS collector? I sometimes get events with cause "No GC". Does this indicate a background CMS cycle being initiated by hitting the occupancy fraction threshold? 3) Eden/Survivor It seems that the MemoryUsage API treats Eden and Survivor separately, i.e. survivor is not a subset of eden. This is different from the gc log presentation. Is my understanding correct? In general, I think it would be useful to have a code sample for the GC notification API that generates output as close as possible to -XX:+PrintGCDetails -verbose:gc, as far as the data required to do so is available. The API looks quite promising, it seems it could really benefit from a bit of documentation love :) Thanks, -tt


hotspot-gc-use mailing list hotspot-gc-use at openjdk.java.net http://mail.openjdk.java.net/mailman/listinfo/hotspot-gc-use

-------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/serviceability-dev/attachments/20130201/37dca1ab/attachment.html



More information about the serviceability-dev mailing list