HP-UX Programmer's Guide for Java 2

Table Of Contents
kill -21 6754
kill -s sigprof 6754
Issuing a second SIGPROF signal to the running Java program prompts the JVM to
stop emitting the -Xverbosegc information. Similarly, issuing yet another SIGPROF
signal to the running process prompts the JVM to start issuing -Xverbosegc
information one more time.
Additionally, starting with this release, and only if you had started the Java application
with -XX:+PrintAllocStatistics, when zero preparation -Xverbosegc is
enabled as specified in the previous paragraph, the JVM also emits detailed allocation
site statistics.
If you start your application with -XX:+PrintAllocStatistics, and if you do not
specify -Xverbosegc, or send the running process a SIGPROF signal, then the JVM
will emit allocation site statistics to standard out when the application terminates. (That
is, when the Java process stops running.) If you do not want to wait for the application
to terminate, or if the application is designed to be long running (or does not terminate),
then you can obtain allocation site statistics by sending the running Java program a
SIGPROF as described above.
Unlike -Xverbosegc information emission in zero preparation mode, which is started
with a SIGPROF and stopped with a second SIGPROF, when
-XX:+PrintAllocStatistics is specified, allocation site statistics is emitted every
time the JVM receives a SIGPROF.
When -XX:+PrintAllocStatistics is specified along with -Xverbosegc,
allocation site statistics data are directed to the same output specified for HP
-Xverbosegc. If no output file is specified, allocation site statistics are directed to
standard out (to the terminal where the program was started from). When
-XX:+PrintAllocStatistics is specified alone (without -Xverbosegc on the
command line), allocation site statistics are directed to standard out (to the terminal).
When a SIGPROF signal is sent to a running Java process that was originally started
with -XX:+PrintAllocStatistics on the command line, the SIGPROF signal will
also enable -Xverbosegc data collection if -Xverbosegc was not specified on the
command line when the program was started, and the output of both -Xverbosegc
and allocation site statistics is directed to a file created for you by the JVM. The name
of the file created by the JVM has the following format: java_<pid>.vgc. Where
<pid> is the Java process id. The following table lists all possible permutations and
corresponding locations of emitted data for both allocation site statistics and zero
preparation -Xverbosegc.
Allocation Site Statistics Data
LocationJVM Flags SpecifiedAction
Standard out
-XX:+PrintAllocStatistics
-Xverbosegc
No special action taken
Same location as -Xverbosegc
data file (mydata.vgc)
-XX:+PrintAllocStatistics
-Xverbosegc:file=mydata.vgc
No special action taken
Allocation Site Statistics and Zero Preparation -Xverbosegc 77