To enable support for mixed-mode profilers use:
Since JDK 8. Previously, Java developers had to use system profilers such as perf command in Linux, together with JVM profilers such as hprof, to get the full picture of their application performance. System profilers only trace system code paths, whereas JVM profilers trace only the Java code paths. The reason profilers could not generate “mixed-mode” profiles (i.e., profile information from both system code path and Java code paths) was a result of how JVM Just In Time (JIT) compilers were implemented. To support mixed-mode profilers, the JVM has added support for the “-XX:+PreserveFramePointer” option. It allows generating flames graphs in mixed-mode (default mode for JVM). Flame graphs are a visualization of hierarchical data, created to visualize stack traces of profiled software so that the most frequent code-paths to be identified quickly and accurately. We can create them for CPU, memory, off-CPU etc. When this option is provided, the JVM will abide by the frame pointer intended semantics and not use it as a general purpose register. Because this option disables a compiler optimization, there could be a small performance hit when this option is turned on. However, since this option is disabled by default, there is no performance impact for the default configuration of the JVM.
By default, it is set to false.
TODO link Xint
If you have additional comments, interesting experiences or even point of disagreement with this JVM argument description, please leave a comment. Your insights will help the entire 10+ million java developer community to develop one standard source of documentation for all the JVM arguments.
Edit your Comment