Skip to content
Kyle Smith edited this page Feb 12, 2016 · 15 revisions

Once you've installed the client into a directory you need to run agent on the JVM that you want to profile. You can then either use the Gui Client or the Commandline Client in order to view the output of the profiler.

The Agent

To run the jvmti agent:

java -agentpath:/path/to/location/liblagent.so=interval=7,logPath=/path/to/output/log.hpl <normal-java-commandline>

Note: "agentpath" does not equal "agentlib"

Additional options:

Option Type Notes
intervalMin int Wait at least this many milliseconds between samples
intervalMax int Wait no longer than this many milliseconds between samples
interval int Sets both intervalMin and intervalMax to the same value with one parameter. Consider a prime number to avoid over-sampling periodically-running methods (e.g., that run every 10 microseconds)
logPath string A file path indicating where the collected data should be written
start boolean "0": Do not profile on initialization (wait for dynamic call to start profiling). "1": Begin profiling as soon as possible.

The Gui Client

To start the Gui you use:

./gui

The Commandline Client

See [How to use the Commandline Client](How to use the Commandline Client)