Skip to content

Commit db0cdac

Browse files
authored
docs: add details on enhanced continuous profiling for JVM (coroot#723)
1 parent 1164692 commit db0cdac

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

docs/docs/inspections/jvm.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,8 @@ So, you don't need to configure anything!
1111
* JVM safepoints: detects situations when a java application has been stopped for a significant amount of time due to safepoint operations
1212

1313
<img alt="JVM" src="/img/docs/jvm.png" class="card w-1200"/>
14+
15+
# Enhanced continuous profiling
16+
For continuous profiling, Coroot uses eBPF as well, capturing execution paths at the kernel level with minimal overhead. However, because the JVM relies heavily on JIT compilation, the generated native code does not include symbolic information by default. In other words, we see memory addresses, but not the actual method names. To make the profiles readable and useful, the JVM needs to expose symbol information. This can be generated using the `jcmd <pid> Compiler.perfmap` command.
17+
18+
Coroot automates this step by periodically calling jcmd in the background. However, the JVM must be started with the `-XX:+PreserveFramePointer` option. This allows for accurate stack traces and proper symbolization of JIT-compiled code, with only a small performance overhead (typically around 1-3%).

0 commit comments

Comments
 (0)