summaryrefslogtreecommitdiff
path: root/gcc/doc/gcov.texi
diff options
context:
space:
mode:
authornathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2002-07-29 18:40:45 +0000
committernathan <nathan@138bc75d-0d04-0410-961f-82ee72b054a4>2002-07-29 18:40:45 +0000
commit958c14b1ad83cd085fb88fa49dda4fde3c5d1998 (patch)
treee199ba3c591b9f03a67f3f435503afb1315dbc13 /gcc/doc/gcov.texi
parent56abe40ca86a390be5f137d421936a6ecd3a56bf (diff)
downloadgcc-958c14b1ad83cd085fb88fa49dda4fde3c5d1998.tar.gz
* profile.c: Add file comment describing the overall algorithm and
structures. (struct edge_info): Add comments. (struct bb_info): Add comments. * basic-block.h (EDGE_*): Add comments. * doc/gcov.texi (Gcov Data Files): Document bit flags. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@55842 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/doc/gcov.texi')
-rw-r--r--gcc/doc/gcov.texi32
1 files changed, 25 insertions, 7 deletions
diff --git a/gcc/doc/gcov.texi b/gcc/doc/gcov.texi
index 5f5f18bd6d1..6b0fd82d852 100644
--- a/gcc/doc/gcov.texi
+++ b/gcc/doc/gcov.texi
@@ -348,12 +348,13 @@ functions within those files, and line numbers corresponding to each
basic block in the source file.
The @file{.bb} file format consists of several lists of 4-byte integers
-which correspond to the line numbers of each basic block in the
-file. Each list is terminated by a line number of 0. A line number of @minus{}1
-is used to designate that the source file name (padded to a 4-byte
-boundary and followed by another @minus{}1) follows. In addition, a line number
-of @minus{}2 is used to designate that the name of a function (also padded to a
-4-byte boundary and followed by a @minus{}2) follows.
+which correspond to the line numbers of each basic block in the file.
+Each list is terminated by a line number of 0. A line number of
+@minus{}1 is used to designate that the source file name (padded to a
+4-byte boundary and followed by another @minus{}1) follows. In
+addition, a line number of @minus{}2 is used to designate that the name
+of a function (also padded to a 4-byte boundary and followed by a
+@minus{}2) follows.
The @file{.bbg} file is used to reconstruct the program flow graph for
the source file. It contains a list of the program flow arcs (possible
@@ -388,6 +389,22 @@ correctly.
The function name is stored as a @minus{}1 (4 bytes), the length (4 bytes),
the name itself (padded to 4-byte boundary) followed by a @minus{}1 (4 bytes).
+The flags are defined as follows:
+@itemize
+@item bit0
+On function spanning tree
+
+@item bit1
+Is a fake edge
+
+@item bit2
+Is the fall through edge from one block to its immediate successor.
+
+@item bit3-bit31
+For future expansion
+
+@end itemize
+
The @file{.da} file is generated when a program containing object files
built with the GCC @option{-fprofile-arcs} option is executed. A
separate @file{.da} file is created for each source file compiled with
@@ -395,7 +412,8 @@ this option, and the name of the @file{.da} file is stored as an
absolute pathname in the resulting object file. This path name is
derived from the source file name by substituting a @file{.da} suffix.
-The @file{.da} consists of several blocks (one for each run) with the following structure:
+The @file{.da} consists of several blocks (one for each run) with the
+following structure:
@smallexample
"magic" number @minus{}123 (4-byte number)
number of functions (4-byte number)