Pristine Ack-5.5
[Ack-5.5.git] / mach / mantra / int / em.1
1 .\" $Id: em.1,v 1.5 1994/06/24 13:08:58 ceriel Exp $
2 .TH EM 1 "$Revision: 1.5 $"
3 .ad
4 .SH NAME
5 em \- calling program for em interpreters
6 .SH SYNOPSIS
7 \fBem\fP [-t] [+fcp] [loadfile [args ... ...] ]
8 .SH DESCRIPTION
9 The loadfile ("e.out" if not specified) is opened to read the first 8 word header.
10 The format of this header is explained in e.out(5).
11 One of these 8 words is a flag word
12 specifying the interpreter options requested at compile time.
13 The usual setting of these options is +t -f -c -p.
14 These options may be overridden at runtime as follows:
15 em -t turns the test option of; em +c turns count on ; em +p turns profile
16 on ; em +c +p turns both count and profile on.
17 Based on these options the name of the appropriate interpreter
18 is constructed.
19 Two versions exist, one for two byte words and four byte pointers and
20 one for four byte words and pointers.
21 The information in the header of the e.out file is used by em to select the 
22 right interpreter for the word size of used in the e.out file.
23 .PP
24 This interpreter is searched for in ~em/lib/em[24]4.
25 .PP
26 The flags control the following options that can be turned off
27 or on by prepending them with - or + respectively:
28 .IP t
29 run time tests for undefined variables, array bounds etc...
30 This option costs a small amount of memory and some time.
31 However, it is very useful for debugging.
32 .IP p
33 profiling of the entire program. The interpreter maintains tables containing
34 an estimate of the number of processor state cycles used per source line.
35 A processor state cycle is equal to two internal clock cycles.
36 This option is expensive in time as well as in memory space.
37 The result tables made at run time are dumped in a human readable
38 format onto a file named
39 em_profile.
40 .IP f
41 maintain a bit map of all source lines that have been executed.
42 This map is written onto a file em_flow .
43 This option is almost free in time and space.
44 The file is not easy to read.
45 Of each procedure only the lines between the first statement and the last
46 statement are represented in the bit map.
47 Currently this option is not installed in the em tree.
48 .IP c
49 count line usage in tables that
50 contains for every source line the number of times it
51 was entered.
52 These tables are written onto em_count, a human readable file .
53 This option is cheap in time, but costs some in memory space.
54 .IP l
55 dump the line numbers of the last 64 lines entered onto a file named
56 em_last.
57 This file will be in a human readable format.
58 This option is used simultaneously with the test option.
59 .PP
60 These flags
61 give rise to 5 different interpreters which are in the
62 directory ~em/lib/em24 or in ~em/lib/em44
63 for the two byte word or the four byte word options, respectively.
64 .PP
65 .SH "FILES"
66 .IP ~em/lib/em[24]4/em_???? 35
67 interpreters proper
68 .IP em_profile
69 profile data
70 .IP em_count
71 source line count data
72 .IP em_flow
73 source line flow data
74 .IP em_last
75 last lines executed
76 .PD
77 .SH "SEE ALSO"
78 \fIack\fP(1),
79 .SH BUGS
80 Most error messages are self explanatory.
81 If runtime flags are turned on it is advisable to try again
82 with the default options.
83 If the interpreter does not work most probably your particular
84 machine has an other format for the system calls then assumed
85 in the source.
86 In that case adapt source file mloopc to your machine.
87 Also the instruction that causes the machine to allocate stack
88 space might differ .
89 In that case adapt the macro \fIclaimstack\fP in deffile.
90 .SH AUTHOR
91 Freek van Schagen