Skip to content
Snippets Groups Projects
Commit 56d88192 authored by David Bühler's avatar David Bühler
Browse files

[Doc] Small improvements to the flame graph section in the Eva user manual.

parent a2e67b9b
No related branches found
No related tags found
No related merge requests found
......@@ -2071,21 +2071,22 @@ In these three cases, the function \lstinline|f| is reached by the analysis
When running long analyses with \Eva{}, you can use option
\texttt{-eva-flamegraph <file>} to obtain profiling information about which
functions are taking time. This option outputs textual data to the specified
\texttt{<file>}, which can then be read by the \texttt{flamegraph.pl} script
developed by Brendan Egg\footnote{\url{https://www.brendangregg.com/flamegraphs.html}}.
This script is available as a package in some Linux distributions, and it is
also included in Frama-C's shared files. The version shipped with Frama-C can
be run with the following command:
C functions are taking time to analyze.
This option outputs textual data to the specified \texttt{<file>},
which can then be read by the \texttt{flamegraph.pl} script developed by
Brendan Egg\footnote{\url{https://www.brendangregg.com/flamegraphs.html}}.
This script is available as a package in some Linux distributions; it is
also included in Frama-C and can be run with the following command:
\begin{listing}{1}
frama-c-script flamegraph <file> [<dir>]
\end{listing}
The \texttt{<file>} argument must be the same given to option
\texttt{-eva-flamegraph}. The \texttt{<dir>} argument is optional, but when
specified, it stores the produced flame graph (in SVG and HTML versions)
in that directory.
This command generates the flame graph from \texttt{<file>},
which must be the same given to option \texttt{-eva-flamegraph},
and opens it in the default web browser.
The \texttt{<dir>} argument is optional, but when specified, it stores the
produced flame graph (in SVG and HTML versions) in that directory.
Figure~\ref{fig:flamegraph} presents an example of a flame graph.
......@@ -2096,9 +2097,10 @@ Figure~\ref{fig:flamegraph} presents an example of a flame graph.
\label{fig:flamegraph}
\end{figure}
These flame graphs are interactive SVGs, which can be wrapped in an HTML page.
It is possible to zoom and filter by name. The length of a bar is proportional
to the time spent in that function. Note that if a function \texttt{f}
These flame graphs are interactive SVGs wrapped in an HTML page.
It is possible to zoom and filter functions by name. The length of a bar is
proportional to the time spent analyzing this function (and all other functions
called from this function). Note that if a function \texttt{f}
contains several callsites for \texttt{g}, only the total aggregated time is
displayed as a single bar \texttt{g} below \texttt{f}.
Finally, note that \texttt{-eva-flamegraph} has a negligible cost in terms of
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment