Skip to content

Commit

Permalink
Merge pull request #46 from kernigh/kernigh-pr-man
Browse files Browse the repository at this point in the history
Tune the installed manual pages.
  • Loading branch information
davidgiven authored Jan 19, 2017
2 parents d7df126 + f91bc28 commit b30eeb4
Show file tree
Hide file tree
Showing 17 changed files with 166 additions and 179 deletions.
47 changes: 16 additions & 31 deletions lang/b/compiler/em_b.6
Original file line number Diff line number Diff line change
@@ -1,68 +1,53 @@
.TH EM_B 6
.TH EM_B 6 2017-01-18
.ad


.SH NAME
em_b \- ACK B compiler


.SH SYNOPSIS
.B ~em/lib/ack/em_b
.RI [ options ]


.RI [ options ]
.SH DESCRIPTION
.I em_b
is a port of the ABC B compiler to the ACK. Interested parties will be
is a port of the ABC B compiler to the ACK.
Interested parties will be
interested in the upstream distribution here:

.nf
.sp
https://github.com/aap/abc
.fi

However, the version here has been heavily modified --- bug reports should be
.PP
However, the version here has been heavily modified \(em bug reports should be
filed with the ACK, not with the upstream compiler.

.PP
Since B was designed for machines with word addressing, some hacking is
required to make it work on modern, byte addressed machines. The generated
required to make it work on modern, byte addressed machines.
The generated
code expects B variables to contain word addresses, and then generates
code to transform these into native addresses before use (which,
unfortunately, impacts performance). However, the ACK's linker doesn't know
unfortunately, impacts performance).
However, the ACK's linker doesn't know
how to emit word addresses into the program's data sections, and so a
separate fixup stage has to happen at runtime, just before \fBmain()\fP,
to convert the byte addresses into word addresses.

.PP
The end result is that using multiple source files with B is somewhat
unwieldy, requiring each module to be explicitly named and then an extra
stage to generate the fixup code. See the \fBack\fP(1) and \fBabmodules\fP(1)
for details.


stage to generate the fixup code.
See the \fBack\fP(1) and \fBabmodules\fP(1) for details.
.SH OPTIONS

.I em_b
accepts the following flags:

.IP \-w\ \fIsize\fP
Sets the word size, used for scaling addresses. Usually either 2 or 4.

Sets the word size, used for scaling addresses.
Usually either 2 or 4.
.IP \-B\ \fIname\fP
Sets the name of the module currently being compiled (used to generate the
fixup table symbol name). Defaults to \fImain\fP if not specified.

fixup table symbol name).
Defaults to \fImain\fP if not specified.
.IP \-i\ \fIfilename\fP
The source B file.

.IP \-o\ \fIfilename\fP
The output compact EM bytecode file.



.SH SEE ALSO
\fIack\fR(1), \fIabmodules\fR(1)

.SH REMARKS
It is very unlikely the \fIem_b\fP will ever be useful for anything.
15 changes: 8 additions & 7 deletions lang/m2/comp/em_m2.6
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
.TH EM_M2 6 "$Revision$"
.TH EM_M2 6 2017-01-18
.ad
.SH NAME
em_m2 \- ACK Modula\-2 compiler
.SH SYNOPSIS
.B ~em/lib.bin/em_m2
.RI [ option ]
.RI [ option ]
.I source
.I destination
.SH DESCRIPTION
Expand All @@ -15,9 +15,9 @@ into EM code.
The input is taken from
.IR source ,
while the
EM code is written on
EM code is written on
.IR destination .
.br
.PP
.I Option
is a, possibly empty, sequence of the following combinations:
.IP \fB\-I\fIdirname\fR
Expand Down Expand Up @@ -65,7 +65,8 @@ make all procedure names global, so that \fIadb\fR(1) understands them.
.IP \fB\-g\fR
produce a DBX-style symbol table.
.IP \fB\-l\fR
enable local extensions. Currently, there are two local extensions:
enable local extensions.
Currently, there are two local extensions:
procedure constants, and the type LONGCARD.
.IP \fB\-s\fR
make INTEGER ranges symmetric, t.i., MIN(INTEGER) = - MAX(INTEGER).
Expand All @@ -77,11 +78,11 @@ disable all range checks.
enable extra array bound checks, for machines that do not implement the
EM ones.
.IP \fB-U\fR
allow for underscores within identifiers. Identifiers may not start with
allow for underscores within identifiers.
Identifiers may not start with
an underscore, even if this flag is given.
.IP \fB-3\fR
only accept Modula-2 programs that strictly conform to [1].
.LP
.SH SEE ALSO
\fIack\fR(1), \fImodula-2\fR(1)
.IP [1]
Expand Down
22 changes: 12 additions & 10 deletions lang/pc/comp/em_pc.6
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.TH EM_PC 6 "$Revision$"
.TH EM_PC 6 2017-01-18
.ad
.SH NAME
em_pc \- Pascal compiler
Expand Down Expand Up @@ -45,36 +45,38 @@ and the \fIn\fR parameter for the alignment of that type.
Absence of \fIm\fR or \fIn\fR causes a default value to be retained.
.IP \fB\-w\fR
suppress warning messages.
.IP
.IP \fB\-R\fR
disable range checks. Additionally, the run-time tests to see if
disable range checks.
Additionally, the run-time tests to see if
a function is assigned, are skipped.
.IP \fB\-A\fR
enable extra array bound checks, for machines that do not implement the
EM ones.
.IP \fB\-C\fR
the lower case and upper case letters are treated differently.
.IP "\fB\-u\fR, \fB\-U\fR"
allow underscores in identifiers. It is not allowed to start an identifier
allow underscores in identifiers.
It is not allowed to start an identifier
with an underscore.
.IP \fB\-a\fR
don't generate code for assertions.
.IP \fB\-c\fR
allow C-like strings. This option is mainly intended for usage with
C-functions. This option will cause the type 'string' to be known.
allow C-like strings.
This option is mainly intended for usage with C-functions.
This option will cause the type 'string' to be known.
.IP \fB\-d\fR
allow the type 'long'.
.IP \fB\-i\fR\fIn\fR
set the size of integer sets to \fIn\fR. When not used, a default value is
retained.
.IP \fB\-s\fR
allow only standard Pascal. This disables the \fB\-c\fR, \fB\-d\fR, \fB\-u\fR,
\fB\-U\fR and \fB\-C\fR
options. Furthermore, assertions are not recognized at all (instead of just
allow only standard Pascal.
This disables the \fB\-c\fR, \fB\-d\fR, \fB\-u\fR,
\fB\-U\fR and \fB\-C\fR options.
Furthermore, assertions are not recognized at all (instead of just
being skipped).
.IP \fB\-t\fR
trace calls and exits of procedures and functions.
.PP
.SH FILES
.IR ~em/lib/em_pc :
binary of the Pascal compiler.
Expand Down
Loading

0 comments on commit b30eeb4

Please sign in to comment.