add .Vx so tmac.andoc will call tmac.mdoc-old
[unix-history] / usr / src / usr.bin / pascal / pxp / pxp.1
CommitLineData
b5dc1377
CL
1.\" Copyright (c) 1980, 1990 The Regents of the University of California.
2.\" All rights reserved.
55cde626 3.\"
b5dc1377 4.\" %sccs.include.redist.man%
55cde626 5.\"
d0719240 6.\" @(#)pxp.1 6.4 (Berkeley) %G%
b5dc1377
CL
7.\"
8.Dd
9.Dt PXP 1
b5dc1377
CL
10.Sh NAME
11.Nm pxp
12.Nd Pascal execution profiler
13.Sh SYNOPSIS
14.Nm pxp
15.Op Fl acdefjnstuw_
16.Op Fl 23456789
17.Op Fl z Op Ar name ...
18.Ar name.p
19.Sh DESCRIPTION
20.Nm Pxp
55cde626
KM
21can be used to obtain execution profiles of Pascal programs or
22as a pretty-printer.
23To produce an execution profile all that is necessary is to translate
24the program specifying the
b5dc1377 25.Fl z
55cde626 26option to
b5dc1377 27.Xr pi 1
55cde626 28or
b5dc1377 29.Xr pix 1 ,
55cde626
KM
30to execute the program,
31and to then issue the command
b5dc1377
CL
32.Pp
33.Dl pxp -x name.p
34.Pp
55cde626 35A reformatted listing is output if none of the
b5dc1377
CL
36.Fl c ,
37.Fl t ,
55cde626 38or
b5dc1377 39.Fl z
55cde626
KM
40options are specified;
41thus
b5dc1377
CL
42.Pp
43.Dl pxp old.p > new.p
44.Pp
55cde626 45places a pretty-printed version of the program in `old.p' in the file `new.p'.
b5dc1377 46.Pp
55cde626 47The use of the following options of
b5dc1377 48.Nm pxp
55cde626 49is discussed in sections 2.6, 5.4, 5.5 and 5.10 of the
b5dc1377
CL
50.Em Berkeley Pascal User's Manual .
51.Tp Fl a
55cde626
KM
52Print the bodies of all procedures and functions in the profile;
53even those which were never executed.
b5dc1377 54.Tp Fl c
55cde626 55Extract profile data from the file
b5dc1377
CL
56.Pa core .
57.Tp Fl d
55cde626 58Include declaration parts in a profile.
b5dc1377 59.Tp Fl e
55cde626 60Eliminate
b5dc1377 61.Ic include
55cde626
KM
62directives when reformatting a file;
63the
b5dc1377 64.Ic include
55cde626
KM
65is replaced by the reformatted contents of the specified
66file.
b5dc1377 67.Tp Fl f
55cde626 68Fully parenthesize expressions.
b5dc1377 69.Tp Fl j
55cde626 70Left justify all procedures and functions.
b5dc1377
CL
71.Tp Fl n
72Eject a new page
55cde626
KM
73as each file is included;
74in profiles, print a blank line at the top of the page.
b5dc1377 75.Tp Fl s
55cde626 76Strip comments from the input text.
b5dc1377 77.Tp Fl t
55cde626 78Print a table summarizing
b5dc1377 79.Ic procedure
55cde626 80and
b5dc1377 81.Ic function
55cde626 82call counts.
b5dc1377 83.Tp Fl u
55cde626
KM
84Card image mode; only the first 72 characters of input lines
85are used.
b5dc1377 86.Tp Fl w
55cde626 87Suppress warning diagnostics.
b5dc1377 88.Tp Fl z
55cde626
KM
89Generate an execution profile.
90If no
b5dc1377
CL
91.Cx Ar name
92.Cx \&\'s
93.Cx
55cde626
KM
94are given the profile is of the entire program.
95If a list of names is given, then only any specified
b5dc1377
CL
96.Cx Ic procedure
97.Cx \&s
98.Cx
55cde626 99or
b5dc1377
CL
100.Cx Ic function
101.Cx \&s
102.Cx
55cde626 103and the contents of any specified
b5dc1377 104.Ic include
55cde626 105files will appear in the profile.
b5dc1377 106.Tp Fl \&_
55cde626 107Underline keywords.
b5dc1377 108.Tp Fl d
55cde626 109With
b5dc1377 110.Ar d
55cde626 111a digit, 2 \(<=
b5dc1377 112.Ar d
55cde626
KM
113\(<= 9,
114causes
b5dc1377 115.Nm pxp
55cde626 116to use
b5dc1377 117.Ar d
55cde626
KM
118spaces as the basic indenting unit.
119The default is 4.
b5dc1377
CL
120.Sh FILES
121.Dw /usr/lib/how_pxp
122.Di L
123.Dp Pa name.p
124input file
125.Dp Pa name.i
126include file(s)
127.Dp Pa pmon.out
128profile data
129.Dp Pa core
130profile data source with
131.Fl c
132.Dp Pa /usr/lib/how_pxp
133information on basic usage
134.Dp
135.Sh SEE ALSO
136.Em Berkeley Pascal User's Manual
55cde626 137.br
b5dc1377
CL
138.Xr pi 1 ,
139.Xr px 1
140.Sh DIAGNOSTICS
55cde626 141For a basic explanation do
b5dc1377
CL
142.Pp
143.Df I
144.Nm pxp
145.De
146.Pp
55cde626
KM
147Error diagnostics include
148`No profile data in file'
149with the
b5dc1377 150.Fl c
55cde626 151option if the
b5dc1377 152.Fl z
55cde626 153option was not enabled to
b5dc1377 154.Nm pi ;
55cde626
KM
155`Not a Pascal system core file'
156if the core is not from a
b5dc1377 157.Nm px
55cde626
KM
158execution;
159`Program and count data do not correspond'
160if the program was changed after compilation, before profiling;
161or if the wrong program is specified.
b5dc1377 162.Sh AUTHOR
55cde626 163William Joy
b5dc1377
CL
164.Sh HISTORY
165.Nm Pxp
166appeared in 3 BSD.
167.Sh BUGS
55cde626 168Does not place multiple statements per line.