adapted to phototypesetter
This commit is contained in:
40
man/libmon.7
40
man/libmon.7
@@ -6,25 +6,25 @@ libmon \- library of system call routines with EM calling sequence
|
||||
.SH DESCRIPTION
|
||||
The modules in this library contain the UNIX system calls with EM calling sequence.
|
||||
This library is written in EM assembly language and can be used
|
||||
for interpreted programs, and 'a.out' programs.
|
||||
for interpreted programs, and \fIa.out\fP programs.
|
||||
If these routines are used in Pascal programs, then the calling sequence
|
||||
requires some attention.
|
||||
Some hints may be useful:
|
||||
.IP -
|
||||
The c-option {$c+} allows you to declare zero-terminated string
|
||||
constants in Pascal like "/etc/passwd".
|
||||
Moreover, the identifier 'string' is then defined as type identifier for
|
||||
Moreover, the identifier \fIstring\fP is then defined as type identifier for
|
||||
a pointer to these zero-terminated strings.
|
||||
.IP -
|
||||
The d-option {$d+} allows you to use double precision integers (longs).
|
||||
The lseek system call, for instance, needs a long argument and returns a long result.
|
||||
.IP -
|
||||
If the system call requires a pointer as argument use a 'var' parameter.
|
||||
If the system call requires a pointer as argument use a \fIvar\fP parameter.
|
||||
For instance declare times as:
|
||||
.br
|
||||
procedure times(var t:timesbuf); extern;
|
||||
.br
|
||||
Note that a 'string' is already a pointer.
|
||||
Note that a \fIstring\fP is already a pointer.
|
||||
.IP -
|
||||
When defining types, use packed records if two bytes must be allocated
|
||||
in a single word, as in
|
||||
@@ -49,44 +49,48 @@ can be declared as:
|
||||
.br
|
||||
creatmode = set of XHIM..SUID;
|
||||
.IP -
|
||||
There are special system call routines 'uread' and 'uwrite' in libpc(VII),
|
||||
because the names 'read' and 'write' are blocked by similar functions in Pascal.
|
||||
There are special system call routines \fIuread\fP and \fIuwrite\fP
|
||||
in libpc(VII),
|
||||
because the names \fIread\fP and \fIwrite\fP
|
||||
are blocked by similar functions in Pascal.
|
||||
.PP
|
||||
The system call 'signal' exists, but uses 'sigtrp'.
|
||||
The system call \fIsignal\fP exists, but uses \fIsigtrp\fP.
|
||||
This EM system call has the
|
||||
following calling sequence:
|
||||
.br
|
||||
function sigtrp(signo,trapno:integer):integer;
|
||||
.br
|
||||
The action values of 'signal', odd for 'ignore' and zero
|
||||
for 'get back to default',
|
||||
The action values of \fIsignal\fP, odd for \fIignore\fP and zero
|
||||
for \fIget back to default\fP,
|
||||
may interfere with the EM procedure identification in some
|
||||
implementations.
|
||||
In most interpreters procedures in EM are numbered consecutively from zero up.
|
||||
The first argument of 'sigtrp' is the signal number 'signo' as for 'signal'.
|
||||
The second argument is an integer 'trapno', indicating the action to be performed
|
||||
The first argument of \fIsigtrp\fP is the signal number \fIsigno\fP
|
||||
as for \fIsignal\fP.
|
||||
The second argument is an integer \fItrapno\fP,
|
||||
indicating the action to be performed
|
||||
when the signal is issued:
|
||||
.IP -2 8
|
||||
Reset the action for signal 'signo' to the default.
|
||||
Reset the action for signal \fIsigno\fP to the default.
|
||||
.IP -3
|
||||
Ignore signal 'signo'.
|
||||
Ignore signal \fIsigno\fP.
|
||||
.IP "0-252"
|
||||
Perform an EM instruction TRP with error code 'trapno',
|
||||
whenever the signal 'signo' is issued.
|
||||
Perform an EM instruction TRP with error code \fItrapno\fP,
|
||||
whenever the signal \fIsigno\fP is issued.
|
||||
Note that the error codes 0-127 are reserved for EM machine errors
|
||||
and language runtime system errors.
|
||||
.PP
|
||||
The routine 'sigtrp' returns the old 'trapno' or -1 if an erroneous
|
||||
The routine \fIsigtrp\fP returns the old \fItrapno\fP or -1 if an erroneous
|
||||
signal number is specified.
|
||||
Only the signal numbers 1, 2, 3, 13, 14, 15 and 16 may be used as argument
|
||||
for 'sigtrp'.
|
||||
for \fIsigtrp\fP.
|
||||
.SH FILES
|
||||
.IP /usr/em/mach/*/lib/tail_mon
|
||||
.PD
|
||||
.SH "SEE ALSO"
|
||||
em(I), ack(I), *(II), libpc(VII)
|
||||
.SH DIAGNOSTICS
|
||||
All routines put the UNIX error code in the global variable 'errno'.
|
||||
All routines put the UNIX error code in the global variable \fIerrno\fP.
|
||||
Errno is not cleared by successful system calls, so it always gives
|
||||
the error of the last failed call.
|
||||
One exception: ptrace clears errno when successful.
|
||||
|
||||
Reference in New Issue
Block a user