1CG_ANNOTATE(1) Release 3.5.0 CG_ANNOTATE(1)
2
3
4
6 cg_annotate - post-processing tool for Cachegrind
7
9 cg_annotate [options] cachegrind-out-file [source-files...]
10
12 cg_annotate takes an output file produced by the Valgrind tool
13 Cachegrind and prints the information in an easy-to-read form.
14
16 -h --help
17 Show the help message.
18
19 --version
20 Show the version number.
21
22 --show=A,B,C [default: all, using order in cachegrind.out.<pid>]
23 Specifies which events to show (and the column order). Default
24 is to use all present in the cachegrind.out.<pid> file (and use
25 the order in the file). Useful if you want to concentrate on,
26 for example, I cache misses (--show=I1mr,I2mr), or data read
27 misses (--show=D1mr,D2mr), or L2 data misses (--show=D2mr,D2mw).
28 Best used in conjunction with --sort.
29
30 --sort=A,B,C [default: order in cachegrind.out.<pid>]
31 Specifies the events upon which the sorting of the
32 function-by-function entries will be based.
33
34 --threshold=X [default: 99%]
35 Sets the threshold for the function-by-function summary.
36 Functions are shown that account for more than X% of the primary
37 sort event. If auto-annotating, also affects which files are
38 annotated.
39
40 Note: thresholds can be set for more than one of the events by
41 appending any events for the --sort option with a colon and a
42 number (no spaces, though). E.g. if you want to see the
43 functions that cover 99% of L2 read misses and 99% of L2 write
44 misses, use this option:
45
46 --sort=D2mr:99,D2mw:99
47
48 --auto=<no|yes> [default: no]
49 When enabled, automatically annotates every file that is
50 mentioned in the function-by-function summary that can be found.
51 Also gives a list of those that couldn't be found.
52
53 --context=N [default: 8]
54 Print N lines of context before and after each annotated line.
55 Avoids printing large sections of source files that were not
56 executed. Use a large number (e.g. 100000) to show all source
57 lines.
58
59 -I<dir> --include=<dir> [default: none]
60 Adds a directory to the list in which to search for files.
61 Multiple -I/--include options can be given to add multiple
62 directories.
63
65 valgrind(1), $INSTALL/share/doc/valgrind/html/index.html or
66 http://www.valgrind.org/docs/manual/index.html.
67
69 Nicholas Nethercote.
70
71
72
73Release 3.5.0 08/19/2009 CG_ANNOTATE(1)