BSD 3 development
[unix-history] / usr / man / man1 / prof.1
CommitLineData
e6817382
BJ
1.TH PROF 1
2.SH NAME
3prof \- display profile data
4.SH SYNOPSIS
5.B prof
6[
7.B \-v
8] [
9.B \-a
10] [
11.B \-l
12] [
13.BI \- "low\fR [ \fB\-\fIhigh\fR ]"
14] [ file ]
15.SH DESCRIPTION
16.I Prof
17interprets the file
18.I mon.out
19produced by the
20.I monitor
21subroutine.
22Under default modes,
23the symbol table in the
24named object file
25.I (a.out
26default)
27is read and correlated with the
28.I mon.out
29profile file.
30For each external symbol, the percentage
31of time spent executing between that symbol
32and the next
33is printed (in decreasing order),
34together with the number of times that routine was called
35and the number of milliseconds per call.
36.PP
37If the
38.B \-a
39option is used,
40all symbols are reported rather than
41just external symbols.
42If the
43.B \-l
44option
45is used,
46the output is listed by
47symbol value rather than
48decreasing percentage.
49.PP
50If the
51.B \-v
52option is used,
53all printing is suppressed
54and a graphic version of the profile
55is produced
56on the standard output for display by the
57.IR plot (1)
58filters.
59The numbers
60.I low
61and
62.I high,
63by default 0 and 100, cause a selected
64percentage of the profile to be plotted
65with accordingly higher resolution.
66.PP
67In order for the number of calls to a routine to be tallied,
68the
69.B \-p
70option of
71.I cc
72must have been given when the file containing the
73routine was compiled.
74This option also arranges for the
75.I mon.out
76file to be produced automatically.
77.SH FILES
78.ta \w'mon.out 'u
79mon.out for profile
80.br
81a.out for namelist
82.SH "SEE ALSO"
83monitor(3), profil(2), cc(1), plot(1)
84.SH BUGS
85Beware of quantization errors.