Mercurial > hg > truffle
view agent/doc/ReadMe-JavaScript.text @ 3766:c3f1170908be
7045330: G1: Simplify/fix the HeapRegionSeq class
7042285: G1: native memory leak during humongous object allocation
6804436: G1: heap region indices should be size_t
Summary: A series of fixes and improvements to the HeapRegionSeq class: a) replace the _regions growable array with a standard C array, b) avoid de-allocating / re-allocating HeapRegion instances when the heap shrinks / grows (fix for 7042285), c) introduce fast method to map address to HeapRegion via a "biased" array pointer, d) embed the _hrs object in G1CollectedHeap, instead of pointing to it via an indirection, e) assume that all the regions added to the HeapRegionSeq instance are contiguous, f) replace int's with size_t's for indexes (and expand that to HeapRegion as part of 6804436), g) remove unnecessary / unused methods, h) rename a couple of fields (_alloc_search_start and _seq_bottom), i) fix iterate_from() not to always start from index 0 irrespective of the region passed to it, j) add a verification method to check the HeapRegionSeq assumptions, k) always call the wrappers for _hrs.iterate(), _hrs_length(), and _hrs.at() from G1CollectedHeap, not those methods directly, and l) unify the code that expands the sequence (by either re-using or creating a new HeapRegion) and make it robust wrt to a HeapRegion allocation failing.
Reviewed-by: stefank, johnc, brutisso
author | tonyp |
---|---|
date | Fri, 10 Jun 2011 13:16:40 -0400 |
parents | a61af66fc99e |
children |
line wrap: on
line source
The HotSpot Serviceability Agent (SA) is a debugger for hotspot core dumps and hung processes. There is a read-only JDI (Java Debugger Interface) implementation on top of SA. This is part of JDK product and the classes are in $JDK/tools/sa-jdi.jar. In addition, there are few serviceability tools in $JDK/bin, namely, jstack (java stack trace tool), jmap (heap tool), jinfo (Java config tool) and jsadebugd. The classes for these are also in sa-jdi.jar file. sa-jdi.jar file is built along with hotspot (libjvm.so) on Solaris and Linux platforms. On Windows platform, SA-JDI is not included and serviceability tools do not use SA. Apart from these, HotSpot SA consists of a number of tools that are *not* included in JDK product bits. The sources and makefile for all-of-SA (including non-productized stuff) are under $HOTSPOT_WS/agent directory. The makefile $HOTSPOT/agent/make directory and shell scripts (and batch files) are used to build and run SA non-product tools. There is also documentation of SA under $HOTSPOT/agent/doc directory. To build complete SA, you need to have Rhino Mozilla jar (js.jar) version 1.5R5 under $HOTSPOT/agent/src/share/lib directory. Rhino is JavaScript interpreter written in Java. Rhino is used to implement SA features such as * SA command line debugger's JavaScript interface - refer to $HOTSPOT/agent/doc/clhsdb.html - refer to $HOTSPOT/agent/doc/jsdb.html * SA simple object query language (SOQL) - language to query Java heap. Rhino's "js.jar" is not included in hotspot source bundles. You need to download it from http://www.mozilla.org/rhino/download.html. Without js.jar, $HOTSPOT/agent/make/Makefile will fail to build. But, note that sa-jdi.jar containing the productized portions of SA will still be built when you build hotspot JVM.