Profiling tools are useful for exploring which methods are run most of the time. They can help you find the most expensive methods and understand exactly how they behave.
IntelliJ IDEA is integrated with the following profiling tools:
Async Profiler: a CPU and memory profiling tool for Linux and macOS.
Java Flight Recorder: a CPU tool provided by Oracle available on Linux, macOS, and Windows.