[RFC] Enhanced Garbage Collection Probe Points
Lukas Berk
lberk at redhat.com
Fri Aug 31 13:06:40 PDT 2012
Hey,
[...]
> > > this gc run. Can this be clarified?
> > I've changed this to: "Word size of the object to be collected."
>
> So, this maybe is not a great improvement. Does this mean that in the
> gc run there will be a single object collected? Is that single object
> @size words big? I think I know better that this is not what you
> mean here, but it reads unclear. Let me ask my question another way,
> is @size a target for this collection run? Or is it the size of the
> region to be collected?
>
> This also introduces a terminology collision for java-centric folks.
> I think you maybe mean 'region' or 'generation' rather than 'object',
> which has a specific meaning in Java-land. This is also an issue
> below...
>
> If the meaning of this value is what I think it is, can I suggest:
>
> "The number of words of memory that this collection will try to reclaim"
As per our discussion on irc, I've changed this to "The collection
should achieve a minimum region of available memory to allow for an
allocation of 'size'." This should satisfy all possible situations where
where @size is used.
>
> > >
> > > + * probe - gc_collect_parallel_scavenge
> > > + *
> > > + * @name: gc_collect_parallel_scavenge
> > > + * @address: address of object being collected
> > > + * @cause: cause of the collection
> > > + *
> > > + * Description: This is a parallel collection, where the jvm
> > > process don't
> > > + * have to halt while the gc is being completed
> > >
> > > I want to make sure I understand this. If I read this correctly,
> > > this
> > > probe fires many times between a begin and end of parallel gc run,
> > > for
> > > each object that is scavenged? If I do understand this, then
> > > saying
> > > "this is a parallel collection" I think is the wrong wording. This
> > > is not a collection, but an event that is part of a collection run.
> > > If
> > > I misunderstand, please clarify :)
> > No, a scavenge is just a miniature collection, not a process within a
> > collection. The mechanics are the same, just not on the entire
> > object
> > space/heap. That being said I've s/This is a parallel
> > collection/This
> > is a parallel scavenge/ to be specific.
>
> I think this is another place where the use of 'object' causes confusion.
> Maybe in this case you mean 'region' or 'generation'?
I've changed it to 'region' to avoid the confusion :)
>
> Another question I have about this; what relationship does this probe
> have to the corresponding _begin and _end probes? Does this probe
> fire near the beginning or near the end or before the beginning or
> after the end? Why do we need this probe, if we already can say
> when this process begins and ends?
This is simply another occurrence (in a different area of the hotspot
code) that corresponds to a scavenge. In order to remain more
consistent, I've split the probe into begin/end probes and renamed it to
reflect the portion of code its located in
(gc_collect_parscavenge_heap_{begin,end}. I've also tweaked the docs to
remain consistent with the 'This marks a ...' style description.
>
> Anyways, this is mainly me being picky about documentation. On the
> technical level, this is fine, so while I think it would be nice to get
> the docs perfect on the first try I don't demand it. If my understanding
> above about semantics of these variables is correct and you'd like to
> accept my suggestions, please do commit this with those tiny updates. If
> my understanding is incorrect, let's not hold this commit back; just put
> it in the way it is, but then I would like to better understand what the
> values those particular probes are telling me (both for if I try to use
> them, and for documenting them for other users!).
>
> That's all I have to say about the patch :)
>
> > >
> > > These numbers do seem to raise some questions, though. Why do we
> > > see such variation between the runs? I'd encourage you to explore
> > > this further. Another aspect to consider: looking at run time of
> > The variations can most likely be attributed to the fact I was
> > running this on a vm on my laptop and had other (non trivial)
> > processes running on the host.
>
> Ah, so these numbers really don't tell us anything at all then!
>
> Maybe we can collaborate on some better methodology...
Sure, I'll contact you off list regarding this.
[...]
> > > probes to the existing set of probe tests?
> > Ideally I'd have some java test programs that would be able to
> > allocate
> > enough objects to trigger collections. As mentioned earlier,
> > different
> > gc algorithms can be specified with jvm options, but what would be
> > tricky is controlling the gc invocation via jvm options in a reliable
> > enough manner that we can reasonably expect scavenges to occur. I
> > would
> > have to experiment with that to see if its possible, if anybody else
> > knows how to easily do that please let me know.
> >
>
> So, this is in some ways analogous to what I struggled with in testing
> some of the existing probes. For example, the probes that fire when
> a method is JIT compiled. This happens (depending on tuning options
> of course) after a certain number invocations of a particular method,
> so in order to test that the probe fires when expected, I wrote a
> java program that did call a certain method the correct number of times,
> and checked that the output indicated the probe firing showing that
> particular method being JIT compiled.
>
> For your problem, instead of controlling the number of times a method
> is called, you need to cause certain amounts of space to be allocated
> for Java objects. You probably to start from some baseline (an empty
> main()), learn about the tuning options that affect the GC behaviour,
> and so forth. I think this is rather non-trivial, another reason why
> not to block the patch for testing. And then, as Mark pointed out in
> his reply, there is also the matter of integrating with the existing
> tests. My apologies in advance about the wrapper script, and please
> consider me available to help when you get to that point.
>
Thanks for the offer, I've already taken a look and once again I'll
contact you off list with any specifics :)
> > Is this ok to commit?
> >
>
> With caveats noted above, I say yes :)
>
Thanks! Please let me know if there is anything else you'd like to know,
updated patch is attached.
Cheers,
Lukas
-------------- next part --------------
diff -r 727519ab8096 Makefile.am
--- a/Makefile.am Fri Aug 24 01:53:20 2012 +0100
+++ b/Makefile.am Fri Aug 31 15:47:32 2012 -0400
@@ -291,7 +291,9 @@
endif
if ENABLE_SYSTEMTAP
-ICEDTEA_PATCHES += patches/systemtap.patch
+ICEDTEA_PATCHES += \
+ patches/systemtap.patch \
+ patches/systemtap_gc.patch
endif
if ENABLE_NSS
@@ -764,6 +766,7 @@
tapset/hotspot.stp.in \
tapset/hotspot_jni.stp.in \
tapset/jstack.stp.in \
+ tapset/hotspot_gc.stp.in \
scripts/jni_create_stap.c \
scripts/jni_desc \
rewriter/agpl-3.0.txt \
@@ -1730,11 +1733,16 @@
sed -e '/\/client\/libjvm.so/d' \
< $(abs_top_builddir)/tapset/hotspot_jni.stp \
> $(BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_jni.stp; \
+ sed -e '/\/client\/libjvm.so/d' \
+ < $(abs_top_builddir)/tapset/hotspot_gc.stp \
+ > $(BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_gc.stp; \
else \
cp $(abs_top_builddir)/tapset/hotspot.stp \
$(BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot.stp; \
cp $(abs_top_builddir)/tapset/hotspot_jni.stp \
$(BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_jni.stp; \
+ cp $(abs_top_builddir)/tapset/hotspot_gc.stp \
+ $(BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_gc.stp; \
fi; \
cp $(abs_top_builddir)/tapset/jstack.stp \
$(BUILD_OUTPUT_DIR)/j2sdk-image/tapset/jstack.stp
@@ -1796,11 +1804,16 @@
sed -e '/\/client\/libjvm.so/d' \
< $(abs_top_builddir)/tapset/hotspot_jni.stp \
> $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_jni.stp; \
+ sed -e '/\/client\/libjvm.so/d' \
+ < $(abs_top_builddir)/tapset/hotspot_gc.stp \
+ > $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_gc.stp; \
else \
cp $(abs_top_builddir)/tapset/hotspot.stp \
$(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot.stp; \
cp $(abs_top_builddir)/tapset/hotspot_jni.stp \
$(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_jni.stp; \
+ cp $(abs_top_builddir)/tapset/hotspot_gc.stp \
+ $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/tapset/hotspot_gc.stp; \
fi; \
cp $(abs_top_builddir)/tapset/jstack.stp \
$(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/tapset/jstack.stp
diff -r 727519ab8096 configure.ac
--- a/configure.ac Fri Aug 24 01:53:20 2012 +0100
+++ b/configure.ac Fri Aug 31 15:47:32 2012 -0400
@@ -315,6 +315,7 @@
AC_CONFIG_FILES([tapset/hotspot.stp])
AC_CONFIG_FILES([tapset/hotspot_jni.stp])
AC_CONFIG_FILES([tapset/jstack.stp])
+ AC_CONFIG_FILES([tapset/hotspot_gc.stp])
fi
dnl Check for libXtst headers and libraries.
diff -r 727519ab8096 patches/systemtap_gc.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/systemtap_gc.patch Fri Aug 31 15:47:32 2012 -0400
@@ -0,0 +1,369 @@
+--- openjdk.orig/hotspot/src/share/vm/compiler/oopMap.cpp 2012-06-26 09:24:22.390325184 -0400
++++ openjdk/hotspot/src/share/vm/compiler/oopMap.cpp 2012-07-06 10:12:44.981413003 -0400
+@@ -33,9 +33,13 @@
+ #include "memory/resourceArea.hpp"
+ #include "runtime/frame.inline.hpp"
+ #include "runtime/signature.hpp"
++#include "utilities/dtrace.hpp"
+ #ifdef COMPILER1
+ #include "c1/c1_Defs.hpp"
+ #endif
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL1(provider, gc__collection__delete, *uintptr_t);
++#endif /* !USDT2 */
+
+ // OopMapStream
+
+@@ -677,6 +681,9 @@
+ " - Derived: " INTPTR_FORMAT " Base: " INTPTR_FORMAT " (Offset: %d)",
+ derived_loc, (address)*derived_loc, (address)base, offset);
+ }
++#ifndef USDT2
++ HS_DTRACE_PROBE1(hotspot, gc__collection__delete, entry);
++#endif /* !USDT2 */
+
+ // Delete entry
+ delete entry;
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/parallelScavenge/psParallelCompact.cpp 2012-07-12 09:48:40.349999515 -0400
++++ openjdk/hotspot/src/share/vm/gc_implementation/parallelScavenge/psParallelCompact.cpp 2012-07-19 18:38:07.560757426 -0400
+@@ -53,11 +53,18 @@
+ #include "runtime/vmThread.hpp"
+ #include "services/management.hpp"
+ #include "services/memoryService.hpp"
++#include "utilities/dtrace.hpp"
+ #include "utilities/events.hpp"
+ #include "utilities/stack.inline.hpp"
+
+ #include <math.h>
+
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__ParallelCompact__clear, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__parallel__collect, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__move, *uintptr_t, *uintptr_t, *uintptr_t, *uintptr_t);
++#endif /* !USDT2 */
++
+ // All sizes are in HeapWords.
+ const size_t ParallelCompactData::Log2RegionSize = 9; // 512 words
+ const size_t ParallelCompactData::RegionSize = (size_t)1 << Log2RegionSize;
+@@ -433,6 +439,9 @@
+
+ void ParallelCompactData::clear()
+ {
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__ParallelCompact__clear, &_region_data, _region_data->data_location());
++#endif /* !USDT2 */
+ memset(_region_data, 0, _region_vspace->committed_size());
+ }
+
+@@ -1970,6 +1979,9 @@
+ "should be in vm thread");
+
+ ParallelScavengeHeap* heap = gc_heap();
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__parallel__collect, heap, heap->gc_cause());
++#endif /* !USDT2 */
+ GCCause::Cause gc_cause = heap->gc_cause();
+ assert(!heap->is_gc_active(), "not reentrant");
+
+@@ -3376,6 +3388,9 @@
+ // past the end of the partial object entering the region (if any).
+ HeapWord* const dest_addr = sd.partial_obj_end(dp_region);
+ HeapWord* const new_top = _space_info[space_id].new_top();
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__move, &beg_addr, &end_addr, &dest_addr, &new_top);
++#endif /* !USDT2 */
+ assert(new_top >= dest_addr, "bad new_top value");
+ const size_t words = pointer_delta(new_top, dest_addr);
+
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/g1/g1MarkSweep.cpp 2012-08-15 12:04:43.837439833 -0400
++++ openjdk/hotspot/src/share/vm/gc_implementation/g1/g1MarkSweep.cpp 2012-08-15 12:01:47.897745719 -0400
+@@ -45,8 +45,13 @@
+ #include "runtime/thread.hpp"
+ #include "runtime/vmThread.hpp"
+ #include "utilities/copy.hpp"
++#include "utilities/dtrace.hpp"
+ #include "utilities/events.hpp"
+
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__G1__begin, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__G1__end, *uintptr_t, *uintptr_t);
++ #endif /* !USDT2 */
+ class HeapRegion;
+
+ void G1MarkSweep::invoke_at_safepoint(ReferenceProcessor* rp,
+@@ -84,6 +89,9 @@
+ // The marking doesn't preserve the marks of biased objects.
+ BiasedLocking::preserve_marks();
+
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__G1__begin, &sh, sh->gc_cause());
++#endif /* !USDT2 */
+ mark_sweep_phase1(marked_for_unloading, clear_all_softrefs);
+
+ mark_sweep_phase2();
+@@ -103,6 +111,9 @@
+ GenRemSet* rs = sh->rem_set();
+ rs->invalidate(sh->perm_gen()->used_region(), true /*whole_heap*/);
+
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__G1__end, &sh, sh->gc_cause());
++#endif /* !USDT2 */
+ // "free at last gc" is calculated from these.
+ // CHF: cheating for now!!!
+ // Universe::set_heap_capacity_at_last_gc(Universe::heap()->capacity());
+--- openjdk.orig/hotspot/src/share/vm/memory/tenuredGeneration.cpp 2012-08-15 12:03:43.009543167 -0400
++++ openjdk/hotspot/src/share/vm/memory/tenuredGeneration.cpp 2012-08-15 12:14:25.414381449 -0400
+@@ -33,6 +33,12 @@
+ #include "memory/tenuredGeneration.hpp"
+ #include "oops/oop.inline.hpp"
+ #include "runtime/java.hpp"
++#include "utilities/dtrace.hpp"
++
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__tenured__begin, bool, bool, size_t, bool);
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__tenured__end, bool, bool, size_t, bool);
++#endif /* !USDT2 */
+
+ TenuredGeneration::TenuredGeneration(ReservedSpace rs,
+ size_t initial_byte_size, int level,
+@@ -307,8 +313,14 @@
+ size_t size,
+ bool is_tlab) {
+ retire_alloc_buffers_before_full_gc();
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__tenured__begin, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
+ OneContigSpaceCardGeneration::collect(full, clear_all_soft_refs,
+ size, is_tlab);
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__tenured__end, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
+ }
+
+ void TenuredGeneration::update_gc_stats(int current_level,
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp 2012-08-15 12:03:43.039543116 -0400
++++ openjdk/hotspot/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp 2012-08-15 12:18:57.181932342 -0400
+@@ -49,6 +49,12 @@
+ #include "utilities/copy.hpp"
+ #include "utilities/globalDefinitions.hpp"
+ #include "utilities/workgroup.hpp"
++#include "utilities/dtrace.hpp"
++
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__parnew__begin, bool, bool, size_t, bool);
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__parnew__end, bool, bool, size_t, bool);
++#endif /* !USDT2 */
+
+ #ifdef _MSC_VER
+ #pragma warning( push )
+@@ -878,6 +884,9 @@
+ bool clear_all_soft_refs,
+ size_t size,
+ bool is_tlab) {
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__parnew__begin, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
+ assert(full || size > 0, "otherwise we don't want to collect");
+ GenCollectedHeap* gch = GenCollectedHeap::heap();
+ assert(gch->kind() == CollectedHeap::GenCollectedHeap,
+@@ -1032,6 +1041,10 @@
+ gch->print_heap_change(gch_prev_used);
+ }
+
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__parnew__end, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
++
+ if (PrintGCDetails && ParallelGCVerbose) {
+ TASKQUEUE_STATS_ONLY(thread_state_set.print_termination_stats());
+ TASKQUEUE_STATS_ONLY(thread_state_set.print_taskqueue_stats());
+--- openjdk.orig/hotspot/src/share/vm/memory/defNewGeneration.cpp 2012-08-15 12:03:43.010543164 -0400
++++ openjdk/hotspot/src/share/vm/memory/defNewGeneration.cpp 2012-08-15 12:21:41.076673646 -0400
+@@ -38,6 +38,7 @@
+ #include "oops/oop.inline.hpp"
+ #include "runtime/java.hpp"
+ #include "utilities/copy.hpp"
++#include "utilities/dtrace.hpp"
+ #include "utilities/stack.inline.hpp"
+ #ifdef TARGET_OS_FAMILY_linux
+ # include "thread_linux.inline.hpp"
+@@ -51,7 +52,10 @@
+ #ifdef TARGET_OS_FAMILY_bsd
+ # include "thread_bsd.inline.hpp"
+ #endif
+-
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__defnew__begin, bool, bool, size_t, bool);
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__defnew__end, bool, bool, size_t, bool);
++#endif /* !USDT2 */
+ //
+ // DefNewGeneration functions.
+
+@@ -528,6 +532,9 @@
+ bool clear_all_soft_refs,
+ size_t size,
+ bool is_tlab) {
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__defnew__begin, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
+ assert(full || size > 0, "otherwise we don't want to collect");
+ GenCollectedHeap* gch = GenCollectedHeap::heap();
+ _next_gen = gch->next_gen(this);
+@@ -661,6 +668,10 @@
+ // does not guarantee monotonicity.
+ jlong now = os::javaTimeNanos() / NANOSECS_PER_MILLISEC;
+ update_time_of_last_gc(now);
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__defnew__end, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
++
+ }
+
+ class RemoveForwardPointerClosure: public ObjectClosure {
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp 2012-08-15 12:03:43.044543106 -0400
++++ openjdk/hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp 2012-08-15 12:25:26.632316692 -0400
+@@ -55,6 +55,12 @@
+ #include "runtime/vmThread.hpp"
+ #include "services/memoryService.hpp"
+ #include "services/runtimeService.hpp"
++#include "utilities/dtrace.hpp"
++
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__contig__begin, bool, bool, size_t, bool);
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__contig__end, bool, bool, size_t, bool);
++#endif /* !USDT2 */
+
+ // statics
+ CMSCollector* ConcurrentMarkSweepGeneration::_collector = NULL;
+@@ -1647,7 +1653,13 @@
+ size_t size,
+ bool tlab)
+ {
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__contig__begin, full, clear_all_soft_refs, size, tlab);
++#endif /* !USDT2 */
+ collector()->collect(full, clear_all_soft_refs, size, tlab);
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__contig__end, full, clear_all_soft_refs, size, tlab);
++#endif /* !USDT2 */
+ }
+
+ void CMSCollector::collect(bool full,
+--- openjdk.orig/hotspot/src/share/vm/memory/generation.cpp 2012-08-15 12:03:43.009543167 -0400
++++ openjdk/hotspot/src/share/vm/memory/generation.cpp 2012-08-15 12:27:46.378095083 -0400
+@@ -39,8 +39,14 @@
+ #include "oops/oop.inline.hpp"
+ #include "runtime/java.hpp"
+ #include "utilities/copy.hpp"
++#include "utilities/dtrace.hpp"
+ #include "utilities/events.hpp"
+
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__contig__begin, bool, bool, size_t, bool);
++ HS_DTRACE_PROBE_DECL4(provider, gc__collection__contig__end, bool, bool, size_t, bool);
++#endif /* !USDT2 */
++
+ Generation::Generation(ReservedSpace rs, size_t initial_size, int level) :
+ _level(level),
+ _ref_processor(NULL) {
+@@ -470,7 +476,13 @@
+ // refs discovery is over the entire heap, not just this generation
+ ReferenceProcessorSpanMutator
+ x(ref_processor(), GenCollectedHeap::heap()->reserved_region());
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__contig__begin, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
+ GenMarkSweep::invoke_at_safepoint(_level, ref_processor(), clear_all_soft_refs);
++#ifndef USDT2
++ HS_DTRACE_PROBE4(hotspot, gc__collection__contig__end, full, clear_all_soft_refs, size, is_tlab);
++#endif /* !USDT2 */
+ SpecializationStats::print();
+ }
+
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/parallelScavenge/psScavenge.cpp 2012-07-25 13:24:07.000000000 -0400
++++ openjdk/hotspot/src/share/vm/gc_implementation/parallelScavenge/psScavenge.cpp 2012-08-17 10:26:44.181117802 -0400
+@@ -51,8 +51,17 @@
+ #include "runtime/vmThread.hpp"
+ #include "runtime/vm_operations.hpp"
+ #include "services/memoryService.hpp"
++#include "utilities/dtrace.hpp"
+ #include "utilities/stack.inline.hpp"
+
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__PSScavenge__begin, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__PSScavenge__end, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__PSParallelCompact__begin, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__PSParallelCompact__end, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__PSMarkSweep__begin, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__PSMarkSweep__end, *uintptr_t, *uintptr_t);
++#endif /* !USDT2 */
+
+ HeapWord* PSScavenge::_to_space_top_before_gc = NULL;
+ int PSScavenge::_consecutive_skipped_scavenges = 0;
+@@ -226,7 +235,13 @@
+ PSAdaptiveSizePolicy* policy = heap->size_policy();
+ IsGCActiveMark mark;
+
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__PSScavenge__begin, *heap, heap->gc_cause());
++#endif /* !USDT2 */
+ const bool scavenge_done = PSScavenge::invoke_no_policy();
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__PSScavenge__end, *heap, heap->gc_cause());
++#endif /* !USDT2 */
+ const bool need_full_gc = !scavenge_done ||
+ policy->should_full_GC(heap->old_gen()->free_in_bytes());
+ bool full_gc_done = false;
+@@ -243,9 +258,21 @@
+ const bool clear_all_softrefs = cp->should_clear_all_soft_refs();
+
+ if (UseParallelOldGC) {
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__PSParallelCompact__begin, *heap, heap->gc_cause());
++#endif /* !USDT2 */
+ full_gc_done = PSParallelCompact::invoke_no_policy(clear_all_softrefs);
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__PSParallelCompact__end, *heap, heap->gc_cause());
++#endif /* !USDT2 */
+ } else {
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__PSMarkSweep__begin, *heap, heap->gc_cause());
++#endif /* !USDT2 */
+ full_gc_done = PSMarkSweep::invoke_no_policy(clear_all_softrefs);
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__PSMarkSweep__end, *heap, heap->gc_cause());
++#endif /* !USDT2 */
+ }
+ }
+
+--- openjdk.orig/hotspot/src/share/vm/gc_implementation/parallelScavenge/parallelScavengeHeap.cpp 2012-07-25 13:24:07.000000000 -0400
++++ openjdk/hotspot/src/share/vm/gc_implementation/parallelScavenge/parallelScavengeHeap.cpp 2012-08-31 15:14:23.936576341 -0400
+@@ -40,8 +40,14 @@
+ #include "runtime/handles.inline.hpp"
+ #include "runtime/java.hpp"
+ #include "runtime/vmThread.hpp"
++#include "utilities/dtrace.hpp"
+ #include "utilities/vmError.hpp"
+
++#ifndef USDT2
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__parscavenge__heap__begin, *uintptr_t, *uintptr_t);
++ HS_DTRACE_PROBE_DECL2(provider, gc__collection__parscavenge__heap__end, *uintptr_t, *uintptr_t);
++#endif /* !USDT2 */
++
+ PSYoungGen* ParallelScavengeHeap::_young_gen = NULL;
+ PSOldGen* ParallelScavengeHeap::_old_gen = NULL;
+ PSPermGen* ParallelScavengeHeap::_perm_gen = NULL;
+@@ -806,7 +812,13 @@
+ }
+
+ VM_ParallelGCSystemGC op(gc_count, full_gc_count, cause);
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__parscavenge__heap__begin, &op, cause);
++#endif /* !USDT2 */
+ VMThread::execute(&op);
++#ifndef USDT2
++ HS_DTRACE_PROBE2(hotspot, gc__collection__parscavenge__heap__end, &op, cause);
++#endif /* !USDT2 */
+ }
+
+ // This interface assumes that it's being called by the
diff -r 727519ab8096 tapset/hotspot_gc.stp.in
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tapset/hotspot_gc.stp.in Fri Aug 31 15:47:32 2012 -0400
@@ -0,0 +1,534 @@
+/*
+ * probe - gc_collect_contig_begin
+ *
+ * @name: gc_collect_contig_begin
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This marks the start of a contiguous space generation collection.
+ *
+ */
+
+probe hotspot.gc_collect_contig_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__contig__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__contig__begin")
+{
+
+ name = "gc_collect_contig_begin";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_contig_end
+ *
+ * @name: gc_collect_contig_end_
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge.
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This marks the end of a contiguous space generation collection.
+ *
+ */
+
+probe hotspot.gc_collect_contig_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__contig__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__contig__end")
+{
+
+ name = "gc_collect_contig_end";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_parnew_begin
+ *
+ * @name: gc_collect_parnew_begin
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This marks the beginning of a parallel collection of a new
+ * generation.
+ *
+ */
+
+probe hotspot.gc_collect_parnew =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__parnew__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__parnew__begin")
+{
+
+ name = "gc_collect_parnew_begin";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_parnew_end
+ *
+ * @name: gc_collect_parnew_end
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This marks the end of a parallel collection of a new
+ * generation.
+ *
+ */
+
+probe hotspot.gc_collect_parnew_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__parnew__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__parnew__end")
+{
+
+ name = "gc_collect_parnew_end";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_defnew_begin
+ *
+ * @name: gc_collect_defnew_begin
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This marks the start of a newly defined generation
+ * collection
+ *
+ */
+
+probe hotspot.gc_collect_defnew_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__defnew__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__defnew__begin")
+{
+
+ name = "gc_collect_defnew_begin";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_defnew_end
+ *
+ * @name: gc_collect_defnew_end
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This marks the end of a newly defined generation
+ * collection
+ *
+ */
+
+probe hotspot.gc_collect_defnew_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__defnew__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__defnew__end")
+{
+
+ name = "gc_collect_defnew_end";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_tenured_begin
+ *
+ * @name: gc_collect_tenured_begin
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This is the start of a collection of a tenured generation
+ * (a generation that has survived multiple garbage collections and is
+ * now in a 'tenured' object space.
+ *
+ */
+
+probe hotspot.gc_collect_tenured_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__tenured__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__tenured__begin")
+{
+
+ name = "gc_collect_tenured_begin";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_tenured_end
+ *
+ * @name: gc_collect_tenured_end
+ * @is_full: If TRUE, attempt a full collection of the generation.
+ * Else; perform a scavenge
+ * @size: The collection should achieve a minimum region of available
+ * memory to allow for an allocation of 'size'.
+ * @is_tlab: Is this a Thread Local Allocation Buffer?
+ *
+ * Description: This is the end of a collection of a tenured generation
+ * (a generation that has survived multiple garbage collections and is
+ * now in a 'tenured' object space.
+ *
+ */
+
+probe hotspot.gc_collect_tenured_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__tenured__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__tenured__end")
+{
+
+ name = "gc_collect_tenured_end";
+ is_full = $arg2;
+ size = $arg3;
+ is_tlab = $arg4;
+ probestr = sprintf("%s(is_full='%d', size='%d', is_tlab='%d')", name, is_full, size, is_tlab);
+
+}
+
+/*
+ * probe - gc_collect_parallel_scavenge_heap_begin
+ *
+ * @name: gc_collect_parallel_scavenge_heap_begin
+ * @address: Address of region being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: This is a parallel heap scavenge beginning, the jvm process doesn't
+ * have to halt while the gc is being completed.
+ */
+
+probe hotspot.gc_collect_parallel_scavenge =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__parscavenge__heap__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__parscavenge__heap__begin")
+{
+ name = "gc_collect_parallel_scavenge_heap_begin";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_parallel_scavenge_heap_end
+ *
+ * @name: gc_collect_parallel_scavenge_heap_end
+ * @address: Address of region being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: This is a parallel heap scavenge ending, the jvm process doesn't
+ * have to halt while the gc is being completed.
+ */
+
+probe hotspot.gc_collect_parallel_scavenge_heap_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__parscavenge__heap__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__parscavenge__heap__end")
+{
+ name = "gc_collect_parallel_scavenge_heap_end";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_parallel_collect
+ *
+ * @name: gc_collect_parallel_collect
+ * @address: Address of object being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks a parallel collection.
+ *
+ */
+
+probe hotspot.gc_collect_parallel_collect =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__parallel__collect"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__parallel__collect")
+{
+ name = "gc_collect_parallel_collect";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_g1_begin
+ *
+ * @name: gc_collect_g1_begin
+ * @address: Address of object being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks the start of a G1 style garbage collection
+ * (Garbage-First Garbage Collector).
+ *
+ */
+
+probe hotspot.gc_collect_g1_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__G1__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__G1__begin")
+{
+ name = "gc_collect_g1_begin";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_g1_end
+ *
+ * @name: gc_collect_g1_end
+ * @address: Address of object being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks then end of a G1 style garbage collection
+ * (Garbage-First Garbage Collector).
+ *
+ */
+
+probe hotspot.gc_collect_g1_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__G1__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__G1__end")
+{
+ name = "gc_collect_g1_end";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_delete
+ *
+ * @name: gc_collect_delete
+ * @address: Address of object being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: A delete statement of an object.
+ *
+ */
+
+probe hotspot.gc_collect_delete =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__delete"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__delete")
+{
+ name = "gc_collect_delete";
+ address = sprintf("0x%x", $arg1);
+ probestr = sprintf("%s(address='%s')", name, address);
+}
+
+/*
+ * probe - gc_collect_PSScavenge_begin
+ *
+ * @name: gc_collect_PSScavenge_begin
+ * @address: Address of scavenge
+ * @cause: Cause of the collection.
+ *
+ * Description: A parallel scavenge begins. A scavenge is a partial garbage
+ * collection which should be much more common than a full garbage collection
+ * throughout the course of the java program.
+ *
+ */
+
+probe hotspot.gc_collect_PSScavenge_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__PSScavenge__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__PSScavenge__begin")
+{
+ name = "gc_collect_PSScavenge_begin";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_PSScavenge_end
+ *
+ * @name: gc_collect_PSScavenge_end
+ * @address: Address of scavenge.
+ * @cause: Cause of the collection.
+ *
+ * Description: The end of the parallel scavenge. The beginning and end of
+ * the scavenge is noted due to the possbility of multiple scavenges occuring
+ * at the same time.
+ *
+ */
+
+probe hotspot.gc_collect_PSScavenge_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__PSScavenge__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__PSScavenge__end")
+{
+ name = "gc_collect_PSScavenge_end";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_PSParallelCompact_begin
+ *
+ * @name: gc_collect_PSParallelCompact_begin
+ * @address: Address of compaction.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks the start of a parallel compaction.
+ *
+ */
+
+probe hotspot.gc_collect_PSParallelCompact_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__PSParallelCompact__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__PSParallelCompact__begin")
+{
+ name = "gc_collect_PSParallelCompact_begin";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_PSParallelCompact_end
+ *
+ * @name: gc_collect_PSParallelCompact_end
+ * @address: Address of compaction.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks the end of a parallel compaction.
+ *
+ */
+
+probe hotspot.gc_collect_PSParallelCompact_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__PSParallelCompact__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__PSParallelCompact__end")
+{
+ name = "gc_collect_PSParallelCompact_end";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_PSMarkSweep_begin
+ *
+ * @name: gc_collect_PSMarkSweep_begin
+ * @address: Address of parallel mark sweep process.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks the start of a parallel mark sweep for
+ * objects that require collection.
+ *
+ */
+
+probe hotspot.gc_collect_PSMarkSweep_begin =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__PSMarkSweep__begin"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__PSMarkSweep__begin")
+{
+ name = "gc_collect_PSMarkSweep_begin";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_PSMarkSweep_end
+ *
+ * @name: gc_collect_PSMarkSweep_end
+ * @address: Address of parallel mark sweep process.
+ * @cause: Cause of the collection.
+ *
+ * Description: This marks the start of a parallel mark sweep for
+ * objects that require collection.
+ *
+ */
+
+probe hotspot.gc_collect_PSMarkSweep_end =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__PSMarkSweep__end"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__PSMarkSweep__end")
+{
+ name = "gc_collect_PSMarkSweep_end";
+ address = sprintf("0x%x", $arg1);
+ cause = $arg2;
+ probestr = sprintf("%s(address='%s', cause='%d')", name, address, cause);
+}
+
+/*
+ * probe - gc_collect_move
+ *
+ * @name: gc_collect_move
+ * @from_bottom_address: The bottom address of the object being moved.
+ * @from_top_address: The top address of the object being moved.
+ * @to_bottom_address: The bottom address of where the object is being moved to.
+ * @to_top_address: The top address of where the object is being moved to.
+ * @cause: Cause of the collection.
+ *
+ * Description: During garbage collections there are times where objects or
+ * blocks of memory need to be moved. This probe will detail from where
+ * the memory is moving and where to.
+ *
+ */
+
+probe hotspot.gc_collect_move =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__move"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__move")
+{
+ name = "gc_collect_move";
+ from_bottom_address = sprintf("0x%x", $arg1);
+ from_top_address = sprintf("0x%x", $arg2);
+ to_bottom_address = sprintf("0x%x", $arg3);
+ to_top_address = sprintf("0x%x", $arg4);
+ probestr = sprintf("%s(from_bottom_address='%s', from_top_address='%s', to_bottom_address='%s', to_top_address='%s')", name, from_bottom_address, from_top_address, to_bottom_address, to_top_address);
+
+}
+
+/*
+ * probe - gc_collect_clear
+ *
+ * @name: gc_collect_clear
+ * @address: Address of object being collected.
+ * @cause: Cause of the collection.
+ *
+ * Description: This probe dictates the region of data that needs to be
+ * cleared in a compaction action.
+ *
+ */
+
+probe hotspot.gc_collect_clear =
+ process("@ABS_CLIENT_LIBJVM_SO@").mark("gc__collection__ParallelCompact__clear"),
+ process("@ABS_SERVER_LIBJVM_SO@").mark("gc__collection__ParallelCompact__clear")
+{
+ name = "gc_collect_clear";
+ region_data = sprintf("0x%x", $arg1);
+ data_location = sprintf("0x%x", $arg2);
+ probestr = sprintf("%s(region_data='%s', data_location='%s')", name, region_data, data_location);
+
+}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20120831/c675d590/attachment.bin
More information about the distro-pkg-dev
mailing list