ugc(8)

NAME
ugc - Trace garbage collection events in high-level languages.

SYNOPSIS
ugc [-h] [-v] [-m] {java,python,ruby,node} pid

DESCRIPTION
This traces garbage collection events as they occur, including their duration and any additional information (such as generation collected or type of GC) provided by the respective language's runtime. This tool relies on USDT probes embedded in many high-level languages, such as Node, Java, Python, and Ruby. It requires a runtime instrumented with these probes, which in some cases requires building from source with a USDT-specific flag, such as "--enable-dtrace" or "--with-dtrace". Since this uses BPF, only the root user can use this tool.

REQUIREMENTS
CONFIG_BPF and bcc.

OPTIONS

-v  Print the resulting BPF program, for debugging purposes.

-m  Print times in milliseconds. The default is microseconds.

{java,python,ruby,node}
    The language to trace.

pid The process id to trace.

EXAMPLES

Trace garbage collections in a specific Node process:
    # ugc node 148

Trace garbage collections in a specific Java process, and print GC times in
    milliseconds: # ugc -m java 6004

FIELDS

START
    The start time of the GC, in seconds from the beginning of the trace.

DESCRIPTION
    The runtime-provided description of this garbage collection event.

TIME
    The duration of the garbage collection event.

OVERHEAD
Garbage collection events, even if frequent, should not produce a considerable overhead when traced because they are still not very common. Even hundreds of GCs per second (which is a very high rate) will still produce a fairly negligible overhead.

SOURCE
This is from bcc.

    https://github.com/iovisor/bcc

Also look in the bcc distribution for a companion _example.txt file containing example usage, output, and commentary for this tool.

OS
Linux

STABILITY
Unstable - in development.

AUTHOR
Sasha Goldshtein

SEE ALSO
trace(8), ustat(8), uobjnew(8)