pal assembler
This commit is contained in:
3
utils/macro/Makefile
Normal file
3
utils/macro/Makefile
Normal file
@@ -0,0 +1,3 @@
|
||||
|
||||
macro8x: macro8x.c
|
||||
cc -o macro8x macro8x.c
|
||||
BIN
utils/macro/macro8x
Executable file
BIN
utils/macro/macro8x
Executable file
Binary file not shown.
140
utils/macro/macro8x.1
Normal file
140
utils/macro/macro8x.1
Normal file
@@ -0,0 +1,140 @@
|
||||
.\" Hey, EMACS: -*- nroff -*-
|
||||
.TH MACRO8X 1 "August 12, 2002"
|
||||
.\" Please adjust this date whenever revising the manpage.
|
||||
.\"
|
||||
.\" Some roff macros, for reference:
|
||||
.\" .nh disable hyphenation
|
||||
.\" .hy enable hyphenation
|
||||
.\" .ad l left justify
|
||||
.\" .ad b justify to both left and right margins
|
||||
.\" .nf disable filling
|
||||
.\" .fi enable filling
|
||||
.\" .br insert line break
|
||||
.\" .sp <n> insert n+1 empty lines
|
||||
.\" for manpage-specific macros, see man(7)
|
||||
.SH NAME
|
||||
macro8x \- PDP8 macro assembler
|
||||
.SH SYNOPSIS
|
||||
.B macro8x [ -d -m -p -r -x ] inputfile inputfile...
|
||||
.SH DESCRIPTION
|
||||
This manual page documents briefly the
|
||||
.B macro8x
|
||||
command.
|
||||
This is a cross-assembler to for PDP/8 assembly language programs.
|
||||
It will produce an output file in bin format, rim format, and using the
|
||||
appropriate pseudo-ops, a combination of rim and bin formats.
|
||||
A listing file is always produced and with an optional symbol table
|
||||
and/or a symbol cross-reference (concordance). The permanent symbol
|
||||
table can be output in a form that may be read back in so a customized
|
||||
permanent symbol table can be produced. Any detected errors are output
|
||||
to a separate file giving the filename in which they were detected
|
||||
along with the line number, column number and error message as well as
|
||||
marking the error in the listing file.
|
||||
.br
|
||||
The following file name extensions are used:
|
||||
.br
|
||||
.pal source code (input)
|
||||
.br
|
||||
.lst assembly listing (output)
|
||||
.br
|
||||
.bin assembly output in DEC's bin format (output)
|
||||
.br
|
||||
.rim assembly output in DEC's rim format (output)
|
||||
.br
|
||||
.err assembly errors detected (if any) (output)
|
||||
.br
|
||||
.prm permanent symbol table in form suitable for reading after the EXPUNGE pseudo-op.
|
||||
.PP
|
||||
.SH OPTIONS
|
||||
.PP
|
||||
.br
|
||||
-d Dump the symbol table at end of assembly
|
||||
.br
|
||||
-m Print macro expansions.
|
||||
.br
|
||||
-p Generate a file with the permanent symbols in it.
|
||||
.br
|
||||
(To get the current symbol table, assemble a file than has only
|
||||
.br
|
||||
a $ in it.)
|
||||
.br
|
||||
-r Produce output in rim format (default is bin format)
|
||||
.br
|
||||
-x Generate a cross-reference (concordance) of user symbols.
|
||||
.PP
|
||||
.SH DIAGNOSTICS
|
||||
Assembler error diagnostics are output to an error file and inserted
|
||||
in the listing file. Each line in the error file has the form
|
||||
.PP
|
||||
<filename>(<line>:<col>) : error: <message> at Loc = <loc>
|
||||
.PP
|
||||
An example error message is:
|
||||
.PP
|
||||
bintst.pal(17:9) : error: undefined symbol "UNDEF" at Loc = 07616
|
||||
.PP
|
||||
The error diagnostics put in the listing start with a two character
|
||||
error code (if appropriate) and a short message. A carat '^' is
|
||||
placed under the item in error if appropriate.
|
||||
.PP
|
||||
An example error message is:
|
||||
.PP
|
||||
.BR
|
||||
17 07616 3000 DCA UNDEF
|
||||
.BR
|
||||
UD undefined ^
|
||||
.BR
|
||||
18 07617 1777 TAD I DUMMY
|
||||
.BR
|
||||
.PP
|
||||
When an indirect is generated, an at character '@' is placed after the
|
||||
the instruction value in the listing as an indicator as follows:
|
||||
.PP
|
||||
14 03716 1777@ TAD OFFPAG
|
||||
.PP
|
||||
Undefined symbols are marked in the symbol table listing by prepending
|
||||
a '?' to the symbol. Redefined symbols are marked in the symbol table
|
||||
listing by prepending a '#' to the symbol. Examples are:
|
||||
.PP
|
||||
#REDEF 04567
|
||||
.BR
|
||||
SWITCH 07612
|
||||
.BR
|
||||
?UNDEF 00000
|
||||
.PP
|
||||
Refer to the (source) code for the diagnostic messages generated.
|
||||
.SH BUGS
|
||||
.PP
|
||||
Only a minimal effort has been made to keep the listing format
|
||||
anything like the PAL-8 listing format.
|
||||
The operation of the conditional assembly pseudo-ops may not function
|
||||
exactly as the DEC versions. I did not have any examples of these so
|
||||
the implementation is my interpretation of how they should work.
|
||||
.PP
|
||||
The RIMPUNch and BINPUNch pseudo-ops do not change the binary output
|
||||
file type that was specified on startup. This was intentional and
|
||||
allows rim formatted data to be output prior to the actual binary
|
||||
formatted data. On UN*X style systems, the same effect can be achieved
|
||||
by using the "cat" command, but on DOS/Windows systems, doing this was
|
||||
a major chore.
|
||||
.PP
|
||||
The floating point input does not generate values exactly as the DEC
|
||||
compiler does. I worked out several examples by hand and believe that
|
||||
this implementation is slightly more accurate. If I am mistaken,
|
||||
let me know and, if possible, a better method of generating the values.
|
||||
.PP
|
||||
.SH HISTORICAL NOTE
|
||||
.PP
|
||||
This assembler was written to support the fleet of PDP-8 systems
|
||||
used by the Bay Area Rapid Transit System. As of early 1997,
|
||||
this includes about 40 PDP-8/E systems driving the train destination
|
||||
signs in passenger stations.
|
||||
.PP
|
||||
.SH AUTHOR
|
||||
.BR
|
||||
Gary A. Messenbrink <gary@netcom.com>
|
||||
.BR
|
||||
MACRO8X modifications: Bob Supnik <bob.supnik@ljo.dec.com
|
||||
.BR
|
||||
.PP
|
||||
This manual page was written by Vince Mulhollon <vlm@debian.org>,
|
||||
for the Debian GNU/Linux system (but may be used by others).
|
||||
4251
utils/macro/macro8x.c
Normal file
4251
utils/macro/macro8x.c
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user