Callgrind Format Specification
events: Instructions
# define file ID mapping
fl=(1) file1.c
fl=(2) file2.c
# define function ID mapping
fn=(1) main
fn=(2) func1
fn=(3) func2
fl=(1)
fn=(1)
16 20
...
3.1.6. Subposition Compression
If a Callgrind data file should hold costs for each assembler instruction of a program, you specify subposition "instr" in
the "positions:" header line, and each cost line has to include the address of some instruction. Addresses are allowed to
have a size of 64 bits to support 64-bit architectures. Thus, repeating similar, long addresses for almost every line in the
data file can enlarge the file size quite significantly, and motivates for subposition compression: instead of every cost
line starting with a 16 character long address, one is allowed to specify relative addresses. This relative specification
is not only allowed for instruction addresses, but also for line numbers; both addresses and line numbers are called
"subpositions".
A relative subposition always is based on the corresponding subposition of the last cost line, and starts with a "+" to
specify a positive difference, a "-" to specify a negative difference, or consists of "*" to specify the same subposition.
Because absolute subpositions always are positive (ie. never prefixed by "-"), any relative specification is non-
ambiguous; additionally, absolute and relative subposition specifications can be mixed freely. Assume the following
example (subpositions can always be specified as hexadecimal numbers, beginning with "0x"):
positions: instr line
events: ticks
fn=func
0x80001234 90 1
0x80001237 90 5
0x80001238 91 6
With subposition compression, this looks like
positions: instr line
events: ticks
fn=func
0x80001234 90 1
+3 * 5
+1 +1 6
12
Содержание Software
Страница 176: ...Valgrind FAQ Release 3 8 0 10 August 2012 Copyright 2000 2012 Valgrind Developers Email valgrind valgrind org ...
Страница 177: ...Valgrind FAQ Table of Contents Valgrind Frequently Asked Questions 1 ii ...
Страница 302: ...README mips based on newer GCC versions if possible 95 ...
Страница 303: ...GNU Licenses ...
Страница 304: ...GNU Licenses Table of Contents 1 The GNU General Public License 1 2 The GNU Free Documentation License 8 ii ...