Flame graphs are a visualization of profiled software, allowing the most frequent code-paths to be identified quickly and accurately. They can be generated using my open source programs, which create interactive SVGs. See the Updates section for other implementations. Recently I've been helping with d3-flame-graph. The x-axis shows the stack profile population, sorted alphabetically (it is not the passage of time), and the y-axis shows stack depth, counting from zero at the bottom. Each rectangle represents a stack frame. The wider a frame is is, the more often it was present in the stacks. The top edge shows what is on-CPU, and beneath it is its ancestry. The colors are usually not significant, picked randomly to differentiate frames. Flame charts were first added by Google Chrome's WebKit Web Inspector (bug). While inspired by flame graphs, flame charts put the passage of time on the x-axis instead of the alphabet.
Features
- Flame graphs can be generated from any profile data that contains stack traces
- Once you have a profiler that can generate meaningful stacks, converting them into a flame graph is usually the easy step
- Flame graphs are a visualization for sampled stack traces, which allows hot code-paths to be identified quickly
- Flame Graphs can work with any CPU profiler on any operating system
- With the flame graph, all the data is on screen at once, and the hottest code-paths are immediately obvious as the widest functions
- DTrace can be used to profile on-CPU stack traces on systems that support it