It is easy to start profiling your application – just open the Profiler tool window from the bottom toolbar, select a running process, and right-click it to choose which profiler to attach. You can then stop profiling and see the results in the same tool window.
Our profiler features different ways to display the collected data. You can choose which one works for you – a flame graph, call tree, or methods list.
IntelliJ IDEA automatically saves profiling results in .jfr for CPU or memory sampling and .hprof for memory snapshots. You can then open them when needed or share the results with your teammates.
This helps you visualize the call stack for a selected thread and see how it changes over time. The wider a stack frame is, the longer the method took to execute. The blue blocks stand for native calls and the yellow ones for Java calls.
This shows the percentage of the CPU time used by the methods, the method execution path in your application, and the total sample count. Call tree is useful for a quick overview of application activity and detection of critical execution paths.
This shows a list of the methods executed while you were profiling your data. All of them are sorted by cumulative sample time. Each selected method has several views that show you either the method’s callers or callees.
This lets you view the data related to JVM events like Class loading, Garbage collection, OS events, and many more.
Watch how profiling tools work
Learn more from the blog
Get Started With Profiling in IntelliJ IDEA
A step-by-step tutorial to help you get started with profiling in IntelliJ IDEA UltimateA detailed tutorial about the profiling in IntelliJ IDEA Ultimate.
5 Best Features for Profiling Java Code In IntelliJ IDEAGravity
The Java profiling features you can't do without.