Skip to content

Commit 7799d09

Browse files
HLilitoshadura
authored andcommitted
Add files via upload
1 parent 30342c0 commit 7799d09

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

rootbench-scripts/README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
## About
2+
3+
flamegraph.sh is a script that generates Flame Graphs for each benchmark in `rootbench.git`. More information on Flame Graphs can be found [here](http://www.brendangregg.com/flamegraphs.html).
4+
5+
## Options
6+
7+
See the USAGE message (--help) for options.
8+
9+
To generate only CPU or only memory Flame Graphs, use `-c` or `-m` respectively. To generate both CPU and memory Flame Graphs for all benchmarks at once run the following command:
10+
```bash
11+
flamegraph.sh -d path/to/rootbench/build/dir -a -c -m
12+
```
13+
14+
To generate Flame Graphs for specific benchmark just run the following command with `-c` or `-m` options or both:
15+
```bash
16+
flamegraph.sh -d path/to/rootbench/build/dir -b path/to/benchmark
17+
```
18+
19+
## Configuration
20+
21+
If `perf` cannot find symbols in the program try to execute the following commands
22+
```bash
23+
echo 0 > /proc/sys/kernel/kptr_restrict
24+
echo 1 > /proc/sys/kernel/sched_schedstats
25+
```
26+
27+
To generate Flame Graphs for each benchmark add `-Dflamegraph=ON` option to your cmake configuration.
28+
29+
```bash
30+
cmake ../rootbench -Dflamegraph=ON
31+
make -j4
32+
ctest -V -R rootbench-CLASSNAMEBenchmarks
33+
```
34+
You can also run the script for Flame Graph generation from your rootbench directory.
35+
The Flame Graphs will be stored in the local rootbench build directory under FlameGraph folder.

0 commit comments

Comments
 (0)