GC data displays are available immediately on
opening a .vgc file that was generated by running
your application with -Xverbosegc or -Xloggc options. This data is presented in the following visualizers:
See also:
For an explanation of Java memory
terminology, see the Sun Developer Network publication Memory Management in the Java HotSpot™ Virtual Machine (.pdf)
For an explanation of Java
memory terminology, see the Sun Developer Network publication Memory Management in the Java HotSpot™ Virtual Machine (http://java.sun.com/j2se/reference/whitepapers/memorymanagement_whitepaper.pdf)
Heap Usage After GC |
 |
This visualizer shows heap usage in the eden space
and in the old, survivor, and permanent generations after each garbage
collection. When viewed with consideration of the type of each event,
this graph provides a general picture of the heap resources minimally
required by an application.
Duration (Stop the World) |
 |
This visualizer shows the amount of stop-the-world time spent for each garbage collection
event.
A well-tuned application shows a relatively large
number of short scavenges with less frequent, but more expensive,
full garbage collections.
This graph is also useful for exposing the cost
of explicit System.gc() method calls within an
application, which often result in expensive and unneeded garbage
collection overhead.
Cumulative Allocation |
 |
This visualizer shows the cumulative amount of
storage for new objects requested by the application over time, which
can indicate the overall progress of the application. Because the
rate at which an application creates new objects is often an indicator
of its performance, changes in the slope of this curve may indicate
opportunities for tuning garbage collection.
To see a more dramatic presentation of incremental
changes in object creation, see the Creation Rate visualizer.
Note that storage recovered by the garbage collector
for unused objects is not deducted from the cumulative amount.
Creation Rate |
 |
This panel shows the incremental object creation
rate for the application as observed at each garbage collection event.
The increment at each data point is the amount of elapsed time since
the previous GC event.
The rate of object creation can be a good measure
of your application's overall performance. By correlating GC
events with changes in the object creation rate, you can discover
opportunities for improving this performance through heap parameter
tuning.
Allocation Site Statistics |
 |
This visualizer displays the sites (methods) in
the JDK and user's Java code
where objects have been created. The display includes the number of
objects created at each site (Invoke Count), the percent of memory allocated to the objects
generated by the compiled portion of the running Java application
(% Allocated), the average size of each
object in bytes (Average Size
(Byte)), and the amount of memory occupied by
the objects (Bytes Allocated). This metric is useful when you choose to decrease heap
pressure by modifying the application code.
The data displayed in this visualizer can be refreshed
from the verbose GC file during
the collection period by clicking the
button. The data display shows the cumulative
results of all the dumps of the allocation sites statistics collected
up to that point or the different allocations
separated by time.
Allocation sites can originate from interpreted
as well as compiled Java code. When specifying –XX:+PrintAllocStatistics, only allocations from compiled code are reported. However, because
the Java Virtual Machine detects and compiles the most active Java
methods as early as possible, the most active allocation sites (the
sites most likely to cause GC performance problems) are reported.
The allocation data can be displayed as
either combined or separated time sets. Use the toolbar button combined
(the default) and separated
to toggle between them.
When the button is toggled to combined, the clock button
is disabled, and the background color is white. The default sort
on this table is determined by % Allocated, and
values in this column are displayed in descending order, from greatest
area of memory use to least. Making code changes first in the area
where memory use is greatest can have more significant impact on the
heap. The Combined Sets and Show Clock
Time entries are also listed under the View menu.
When the button is toggled to separated, a Time column
is added to the left side of the table to display the time at which
the allocations were made, and the clock button
on the toolbar is enabled to let you choose clock time or elapsed
time. If the table has more than one time set, the background color
of the first set will be white, the second will be gray, the third
will be white again, and so on. The default sort on this table is
determined by Time, with values in this column
displayed in ascending order.
The filter button
opens a pop-up dialog box where
you can provide various filters to narrow down the data. A Filter entry is also listed under the Edit menu.
If the sets are combined, the columns and
filter dialog box show as combined. With the filter dialog box still displayed, pressing the Toggle Allocation Data into Combined or Separated Sets button would then show the columns and filter dialog box as separated.
Enter filter field values to narrow down the data and then click Apply Filters for the results. To display the complete Allocation Site Statistics table again, click Reset and Apply Filters.
Filter Field Descriptions:
Time – Only visible for
separated sets. Select the time set from the dropdown list, which
contains a sorted list of all time sets for the GC file. If there
is more than one time set, the value All is also
listed, which if chosen will display all time sets for this GC file
in the table.
% Allocated – Choose the
equality = (the default), or one
of the the comparative operators (> or <) from the dropdown list,
and then supply a percentage value in the text field using numbers
0-9, and the decimal point (.) or percent (%) characters. Both 0.01 and 0.01% will supply a filter value of .01%.
Bytes Allocated – Use the
equality or comparitive operators and supply a numerical value in
the text box.
Invoke Count – Use the
equality or comparitive operators and supply a numerical value in
the text box.
Average Size – Use the
equality or comparitive operators and supply a numerical value in
the text box using numbers 0-9, and optional comma. Both 10,000 and
10000 will supply a filter value of 10,000.
Allocation Site – Enter
any characters to match an allocation site listed in the table. Wildcards
are allowed. You can enter the entire string or part of a string,
making sure to match lowercase and uppercase. If an allocation site
listed as a row in the table contains more than one string entered
in the filter, any string that matches will match that row.
Type – Enter any characters
to match an allocation site type listed in the table. Wildcards are
allowed. You can enter the entire string or part of a string, making
sure to match lowercase and uppercase.
How a Snapshot of Allocation Sites Statistics is Shown in GC
Visualizers
User-Defined X-Y Axes |
 |
This visualizer is supplied to help you to experiment
with your own combinations of data gathered by -Xverbosegc or -Xloggc.
Select variables for the X and Y axes from the
drop-down lists. HPjmeter plots the X-Y relationships for your captured
data file. For a partial list of available metrics, see –Xverbosegc and –Xloggc Options and Their Corresponding
Metrics.
For some user-defined selections,
it is possible that the data capture obtained the GC type without
being able to ascertain the numerical value of the data point. Data
points with unknown numerical values are shown in gray near zero (0)
on the X or Y axis of a graph. To determine the GC type of a data
point, check the color in the legend given below the graph.
Multiple User-Defined |
 |
This visualizer is supplied to help you experiment
with your own combinations of data gathered by -Xverbosegc or -Xloggc, including Glance Data that you might have collected. The Heap
Usage After GC metric is shown by default.
Click the
toolbar button to open a metric configuration
pop-up box that lets you select the metrics you want to display:
Choose the Metric Selection Mode by clicking
the Single or Multiple metric
radio button. Then click the check boxes to select the desired metric
or combination of metrics. When you check a metric, it is immediately
added to the chart. Uncheck it, and it is removed from the chart.
When displaying multiple metrics, HPjmeter tries to share the
default y-axis if possible. If not, it creates additional y-axes to
the right of the graph, in units appropriate to the selected metrics.
For example, Figure 8-35 shows four metrics, but only three y-axes. The units for the Heap
Usage After GC and Old After metrics are MBytes, so they share the
same default MBytes y-axis to the left of the graph. The GC Count
units are in integers (indicated by Count), and the Cumulative GC
Duration units are in seconds, so they are each given their own y-axis.
For a partial list of available metrics, see –Xverbosegc and –Xloggc Options and Their Corresponding
Metrics.
If Glance data was collected, then the Glance metrics are also
included for selection in the metric configuration pop-up box.
Glance Data |
 |
The Glance Adviser visualizer
displays a subset of HP GlancePlus metrics collected during a Java
application run.
The metrics display as the Y-axis values on the graph. These
metrics provide information about the global state of the HP-UX server
and the specific process that was selected by process id (pid) when
the Glance data collection was started. By default, the visualizer
displays the Process CPU metric:
You can display a different Glance metric or a combination of
multiple metrics using the
toolbar button. This opens a metric configuration
pop-up box that lets you select the metrics you want to display:
Click the Single or Multiple metric radio button to choose the Metric Selection Mode. Then click the check boxes to select the desired metric or combination
of metrics. When you check a metric, it is immediately added to the
chart. Uncheck it, and it is removed from the chart.
You can also view these metrics together with GC metrics and
Glance system call metrics on the Multiple User-Defined tab.
Table 8-2 “Metrics Shown in Glance Adviser Visualizer” describes
the metrics available for display in the metric configuration pop-up
box of the Glance Adviser visualizer. For additional
detail on these metrics, see the HP GlancePlus for HP-UX
Dictionary of Operating System Performance Metrics provided
with your HP GlancePlus product.
Table 8-2 Metrics Shown in Glance Adviser Visualizer
| Glance Adviser Metric Name | HP GlancePlus
Dictionary Metric Name | Description |
|---|
| Global Swap Utilization | GBL_SWAP_SPACE_UTIL | Percent of available
swap space that was being used by running processes in the interval. |
| Global File Table | TBL_FILE_TABLE_UTIL | Percentage of file table
entries currently used by file descriptors.This metric is updated
every 30 seconds or the sampling interval, whichever is greater. |
| Global CPU | GBL_CPU_TOTAL_UTIL | Percentage of time the
CPU was not idle during the interval. |
| Global System Mode CPU | GBL_CPU_SYS_MODE_UTIL | Percentage
of time the CPU was in system mode during the interval. |
| Global User Mode CPU | GBL_CPU_USER_MODE_UTIL | Percentage
of time the CPU was in user mode during the interval. |
| Run Queue Average | GBL_RUN_QUEUE | Average number of threads waiting
in the run queue over the interval. |
| Global Private Virtual Memory | GBL_MEM_VIRT | Total private virtual
memory (in MBs unless otherwise specified) at the end of the interval.
This is the sum of the virtual allocation of private data and stack
regions for all processes. |
| Physical Memory Utilization | GBL_MEM_UTIL | Percentage of physical
memory in use during the interval. This includes system memory (occupied
by the kernel), buffer cache and user memory. On HP-UX 11iv3 and above,
this includes file cache also. |
| Global Pageout Rate | GBL_MEM_PAGEOUT_RATE | Total number
of page outs to the disk per second during the interval. This reflects
paging activity between memory and paging space. It does not include
activity between memory and file systems. |
| Global Cumulative Pageout Rate | GBL_MEM_PAGEOUT_RATE_CUM | Average
number of page outs to the disk per second over the cumulative collection
time. This includes pages paged out to paging space and to the file
system. |
| Global Buffer Cache Hit | GBL_MEM_CACHE_HIT_PCT | Percentage
of buffer cache reads resolved from the buffer cache (rather than
going to disk) during the interval. Buffer cache reads can occur
as a result of a logical read (for example, file read system call),
a read generated by a client, a read-ahead on behalf of a logical
read, or a system procedure. |
| Global Disk IO Rate | GBL_DISK_PHYS_IO_RATE | Number of physical
IOs per second during the interval. Only local disks are counted in
this measurement. NFS devices are excluded. All types of physical
disk IOs are counted, including file system IO, virtual memory IO,
and raw IO. |
| Global Net Inbound Packet Rate | GBL_NET_IN_PACKET_RATE | Number
of successful packets per second received through all network interfaces
during the interval. Successful packets are those that have been
processed without errors or collisions. |
| Global Net Inbound Error Rate | GBL_NET_IN_ERROR_RATE | Number
of inbound errors per second on all network interfaces during the
interval. |
| Global Net Outbound Packet Rate | GBL_NET_OUT_PACKET_RATE | Number
of successful packets per second sent through the network interfaces
during the interval. Successful packets are those that have been processed
without errors or collisions. |
| Global Net Outbound Error Rate | GBL_NET_OUT_ERROR_RATE | Number
of outbound errors per second on all network interfaces during the
interval. |
| Process CPU | PROC_CPU_TOTAL_UTIL | Total CPU time consumed
by a process or kernel thread as a percentage of the total CPU time
available during the interval. |
| Process System Mode CPU | PROC_CPU_SYS_MODE_UTIL | Percentage
of time that the CPU was in system mode in the context of the process
or kernel thread during the interval. |
| Process User Mode CPU | PROC_CPU_USER_MODE_UTIL | Percentage
of time the process or kernel thread was using the CPU in user mode
during the interval. |
| Process Virtual Memory | PROC_MEM_VIRT | Size (in KB) of virtual
memory allocated for the proces or kernel thread. |
| Process Resident Memory | PROC_MEM_RES | The size (in KB) of resident
memory allocated for the process or kernel thread. |
| Data Region Virtual Memory | PROC_REGION_VIRT_DATA | Size (in
KBs unless otherwise indicated) of the total virtual memory occupied
by data regions of this process. This value is not affected by the
reference count since all data regions are private. |
| Data Region Resident Memory | PROC_REGION_RES_DATA | Size (in
KBs unless otherwise indicated) of the total resident memory occupied
by data regions of this process. This value is not affected by the
reference count since all data regions are private. |
| Process Kernel Threads | PROC_THREAD_COUNT | Total number of
kernel threads for the current process. |
| Process Open Files | PROC_FILE_OPEN | Number of files the
current process has remaining open as of the end of the interval. |
| Process Physical IO Rate | PROC_IO_BYTE_RATE | Number of physical
IO KBs per second used by this process or kernel thread, either directly
or indirectly, during the interval. |
| Process Physical Disk IO Rate | PROC_DISK_PHYS_IO_RATE | Average
number of physical disk IOs per second made by the process or kernel
thread during the interval. |
Glance System Call Data |
 |
The Glance System Call display provides
a graph of data obtained from the PROC_SYSCALL loop in Glance Plus.
For additional details, see the HP GlancePlus for HP-UX
Dictionary of Operating System Performance Metrics. At
each sampling interval, all system calls that exceed a predefined
rate are written to the data file. Six items are recorded for each
system call. They are shown below, with the GlancePlus items they
correspond to in parentheses:
Count for this system call since the last sample (PROCSYSCALL_CALL_COUNT)
Cumulative count for this system call (PROCSYSCALL_CALL_COUNT_CUM)
Rate for this system call (PROCSYSCALL_CALL_RATE)
Cumulative rate for this system call (PROCSYSCALL_CALL_RATE_CUM)
Time spent in this system call (PROCSYSCALL_TOTAL_TIME)
Cumulative time spent in this system call (PROCSYSCALL_TOTAL_TIME_CUM)
These metrics provide information about the system call behavior
of the selected process. You can use the display to look for high
system call activity.
You can display a different Glance system call metric or a combination
of multiple metrics using the
toolbar button. This opens a metric configuration
pop-up box that lets you select the metrics you want to display:
Click the Single or Multiple metric radio button to choose the Metric Selection Mode. Then click the check boxes to select the desired metric or combination
of metrics. When you check a metric, it is immediately added to the
chart. Uncheck it, and it is removed from the chart.
You can also view these metrics together with GC metrics and
Glance Adviser metrics on the Multiple User-Defined tab.