|
|
1.1 root 1: .LP
2: The following monadic
3: i-beam functions are available:
4: .sp
5: .IP 20 5
6: This i-beam returns the time-of-day
7: as the total number of
8: 1/60 seconds which
9: have elapsed since
10: midnight.
11: Division by 60 gives
12: the number of seconds
13: since midnight,
14: etc.
15: .IP 21
16: This i-beam returns the total
17: amount of CPU time used by
18: the current \*a session in
19: 1/60 seconds.
20: This includes the amount of
21: time spent by the system
22: performing I/O
23: (sys time)
24: and computational time
25: (``user'' time).
26: .IP 22
27: This i-beam returns the
28: number of 8-bit bytes
29: which are left in the
30: workspace.
31: However,
32: this value is not really meaningful
33: since the in-core
34: workspace will be expanded,
35: if possible,
36: when full.
37: .IP 24
38: This i-beam returns the
39: time-of-day
40: (in 1/60 seconds)
41: when the current \*a
42: session was begun.
43: .IP 25
44: This i-beam returns the
45: current date as a 6-digit
46: number of the form
47: \fImmddyy\fR.
48: Thus,
49: February 23, 1978
50: would be 022378.
51: .IP 26
52: This i-beam returns the
53: line number in the function
54: currently being executed.
55: Thus,
56: if it is used in line 3
57: of a function,
58: it will return 3.
59: .IP 27
60: This i-beam returns a
61: vector of the line numbers
62: in pending functions
63: (functions which called the
64: current function and are
65: waiting for its completion).
66: .IP 28
67: This i-beam returns the
68: date
69: (as a 6-digit number,
70: \fImmddyy\fR)
71: when the current \*a session began.
72: .IP 29
73: This i-beam returns the
74: current origin,
75: set by the ``)origin''
76: system command.
77: .IP 30
78: This i-beam returns the
79: current width,
80: as set by the ``)width''
81: system command.
82: .IP 31
83: This i-beam returns the
84: current number of digits
85: to be displayed,
86: as set by the ``)digits''
87: system command.
88: .IP 32
89: This i-beam returns the
90: number of workspace bytes
91: which are being used.
92: It is the complement of
93: i-beam 22,
94: which tells how many
95: bytes are unused.
96: Thus,
97: the maximum workspace size
98: (in bytes)
99: can be calculated by
100: adding i-beams 22 and 32.
101: .IP 36
102: This i-beam returns the
103: second element of the
104: vector returned by i-beam
105: 27 \(em
106: that is,
107: it returns the
108: line number of the
109: function which called
110: the current function.
111: .IP 40
112: This i-beam returns the
113: total amount of CPU time
114: spent by any child processes
115: of \*a.
116: Children of \*a include the
117: editor,
118: the shell if ``)shell'' is
119: used,
120: anything run by ``Lrun'',
121: and any processes executed
122: using ``Lfork''.
123: .IP 41
124: This i-beam returns the total
125: amount of ``user''
126: time spent by \*a
127: and all of its children.
128: .IP 42
129: This i-beam returns the total
130: ``system'' time
131: spent by \*a and all of its
132: children.
133: .IP 43
134: This i-beam returns the
135: total amount of ``user''
136: time
137: (computational time)
138: spent by \*a.
139: .IP 44
140: This i-beam returns the
141: total amount of ``sys''
142: (I/O and other system calls)
143: time spent by \*a.
144: .IP 95
145: This i-beam causes \*a to
146: print out its namelist table.
147: It is intended for system development
148: of \*a.
149: .IP 96
150: This i-beam causes \*a to
151: dump its stack on the terminal.
152: It is intended for system
153: development of \*a,
154: and is probably useful
155: only in generating a big
156: messy-looking display.
157: .IP 97
158: This i-beam returns
159: the total number of elements
160: on \*a's internal stack.
161: It is intended for system
162: development and debugging of
163: \*a itself.
164: .IP 98
165: This i-beam function turns off
166: the trace of all memory allocations
167: and deallocations which i-beam
168: 99 turns on.
169: It returns a 1 if the trace was
170: on,
171: and a 0 if it was off already.
172: .IP 99
173: This i-beam turns on the
174: alloc/free trace mentioned above,
175: which i-beam 98 turns off.
176: It also returns a 1 if the
177: trace was already on,
178: or a 0 if it was off.
179: .sp 2
180: .LP
181: The following dyadic
182: i-beam functions were implemented
183: to compensate for the lack of
184: sufficient quad variables.
185: They may be subject to future
186: change.
187: The function is specified
188: by the right argument,
189: the left argument is a parameter
190: to that function.
191: The available i-beams are:
192: .IP 29 5
193: This i-beam may be used to set
194: the origin to any permitted value.
195: The left argument specifies
196: the new origin,
197: and the previous origin is returned.
198: .IP 30
199: This i-beam may be used to set
200: the terminal width to any permitted
201: value.
202: The left argument specifies
203: the new width,
204: and the previous width is returned.
205: .IP 31
206: This i-beam may be used to set
207: the number of digits displayed to
208: any permitted value.
209: The left argument specifies
210: the new number of digits,
211: and the previous value is returned.
212: .IP 34
213: This i-beam implements the system
214: ``nice'' function.
215: The ``nice'' of the \*a process will
216: be set to the value specified by the
217: left argument.
218: A zero will be returned for
219: success,
220: a \(mi1 is returned for failure.
221: This is intended for
222: background processing,
223: not interactive use of \*a.
224: .IP 35
225: This i-beam implements the system
226: ``sleep'' function.
227: \*a will suspend itself for the
228: number of seconds specified
229: (by the left argument).
230: The value returned is the value
231: of the left argument.
232: .IP 63
233: This i-beam implements the system
234: ``empty'' function.
235: The left argument specifies a file
236: descriptor of a pipe.
237: If the pipe is empty,
238: a 1 will be returned,
239: if not-empty, a 0 will be returned.
240: A \(mi1 will be returned if
241: the file descriptor is illegal
242: or is not a pipe.
243: .IP 90
244: Normally,
245: \*a
246: will not exit if it reads an
247: end-of-file from a terminal.
248: This safety feature may be
249: disabled by using i-beam 90
250: with a zero left argument.
251: A non-zero left argument restores
252: the requirement that the user
253: exit with ``)off''
254: or ``)continue''.
255: [Note:
256: this feature cannot be enabled
257: if the input device is not a terminal.]
258: .IP 99
259: This i-beam causes the buffered version
260: of APL to flush the buffer associated with
261: the file descriptor specified as the left
262: argument.
263: A 0 is returned for success,
264: \(mi1 for failure.
265: In unbuffered APL,
266: 0 is always returned and no action is
267: taken
268: (since the command is meaningless).
269: Note that flushing a pipe used for
270: input may cause information to be
271: lost.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.