1
0
Files
irix-657m-src/irix/cmd/btool/man/bmatch.1
2022-09-29 17:59:04 +03:00

83 lines
3.0 KiB
Groff

'\"macro stdmacro
.TH BMATCH 1
.SH NAME
bmatch \- match branch tool report to source code listing
.SH SYNOPSIS
.B bmatch <
.I report_file
.SH DESCRIPTION
.LP
.B bmatch
reads a \fBreport_file\fR produced by breport(1) and prints an annotated
source listing
of the files in it. Each file is printed to standard output; the
lines of the file are preceded by the line number, type of the branch,
number of times taken in the true direction, and number of times taken
in the false direction. The counts for cases and defaults are in the
true-direction column.
.LP
If more than one branch appears on a line, the information for
the first branch is as described above. The counts for the other
branches are printed on following lines. The line number and text of
the line are omitted to make it clear that this is information for the
same line.
.LP
The branch types are written as IF (if), WH (while), QU (question mark
operator), FO (for), DO (do-while), CA (case), DF (default), FU (function).
.LP
Since the output contains source lines and lengthy prefix information,
this tool is best used to make landscape-mode printouts. For online
use, error(1) or the Emacs next-error function may be more convenient.
.LP
In the following example, long lines have been truncated to fit into
80 columns.
.RS
.nf
host-1% breport log | bmatch
../testdir/test1.c
1: : : :/* This testing program distinguishes
2: : : :/* classes :
3: : : :/* branches (if, if else, while, do wh
4: : : :/* nested ( ? )
5: : : :/* sequential (if-if, if-while, if-do
6: : : :/* if else-while, etc, as
7: : : :/* expr. type (scalar, floating, poin
[Omitted lines]
57:IF: 1: 0:if (pi)
58: : : : ;
59: : : :else
60: : : : ;
61: : : :
62: : : :/* sequential combinations
63: : : :/*
64: : : :/* if if one one line, else if
65: : : :
66: : : :i3 = 1;
67: : : :i2 = 0;
68: : : :
69:IF: 1: 0:if (i3) if (i2) { if (i3) printf ("wro
:IF: 0: 1:
:IF: 0: 0:
70:IF: 1: 0: else if (i3);
71: : : :;
72: : : :
73: : : :/* while statement with nested ? opera
74: : : :
75: : : :
76:WH: 8: 1:while ((i3++,i3<10)?1:0) {
:QU: 8: 1:
.fi
.br
.SH "SEE ALSO"
.BR bmerge (1),
.BR bsummary (1),
.BR brestore (1),
.BR btell (1),
.BR btool (1).
.LP
This is a user-contributed tool, written by Jeff Hostetler.