mirror of
https://github.com/PDP-10/its.git
synced 2026-01-11 23:53:12 +00:00
MACN11 - PDP-11 cross assembler.
This commit is contained in:
parent
bcf2657046
commit
2dc2b8436f
@ -667,6 +667,17 @@ expect ":KILL"
|
||||
respond "*" ":cwd budd\r"
|
||||
respond "*" ":palx live palx\r"
|
||||
|
||||
# MACN11, pdp-11 cross assembler
|
||||
respond "*" ":cwd decsys\r"
|
||||
macro10 "macn11" "macn11.hdr,macn11.mac"
|
||||
respond "*" ":dec sys:loader\r"
|
||||
respond "*" "macn11/g\r"
|
||||
expect "EXIT"
|
||||
respond "*" ":start 45\r"
|
||||
respond "Command:" "d"
|
||||
respond "*" ":pdump sys3; ts macn11\r"
|
||||
respond "*" ":kill\r"
|
||||
|
||||
# Cookie Bear
|
||||
respond "*" ":midas gls; ts check_gls; check\r"
|
||||
respond "DEBUGP==" "0\r"
|
||||
|
||||
@ -283,6 +283,8 @@ decsys/lnklod.shr 197811110602.40
|
||||
decsys/lnkscn.shr 197811110609.48
|
||||
decsys/lnkxit.shr 197811110601.58
|
||||
decsys/loader.shr 197603142216.18
|
||||
decsys/macn11.hdr 197411160000.00
|
||||
decsys/macn11.mac 197501140000.00
|
||||
decsys/macro.shr 197603142216.26
|
||||
decsys/macten.mac 197501040000.00
|
||||
decsys/sits.mac 197609010303.16
|
||||
@ -887,6 +889,7 @@ info/lispt.22 197803112120.26
|
||||
_info_/lisp.trace 197501181143.25
|
||||
_info_/lisp.whovar 198102200255.12
|
||||
_info_/lmodem.help 198106051040.17
|
||||
info/macn11.doc 197411060000.00
|
||||
info/macsym.12 198303130147.18
|
||||
info/mail.12 198201140231.54
|
||||
info/meter.1 197707100346.21
|
||||
|
||||
358
doc/info/macn11.doc
Normal file
358
doc/info/macn11.doc
Normal file
@ -0,0 +1,358 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
MACN11 is a PDP-11 MACRO language assembler which operates
|
||||
on the PDP-10. This document describes version 3 of MACN11; with
|
||||
the exception of differences listed in the following pages, it is
|
||||
compatible with the language accepted by MACRO-11 under DOS
|
||||
Version 9, as described in DEC's DOS/BATCH assembler manual
|
||||
(order no. DEC-11-LASMA-A-D).
|
||||
|
||||
Bug reports, comments, and suggestions concerning either
|
||||
version of MACN11 are welcome via net mail to Raveling@ISIB.
|
||||
|
||||
Notes on MACN11 Version 3 Page 2
|
||||
|
||||
|
||||
|
||||
-------- Language Variations from MACRO-11 ---------
|
||||
|
||||
|
||||
|
||||
<< Features not yet supported >>
|
||||
|
||||
|
||||
.PSECT -- Not recognized at present.
|
||||
.DSABL REG -- Parsed properly but ignored;
|
||||
Register definitions are always enabled
|
||||
at present.
|
||||
|
||||
|
||||
Both of these features will be supported in version 4.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<< Differences in defaults >>
|
||||
|
||||
|
||||
Default modes for the .LIST/.NLIST and .ENABL/.DSABL
|
||||
directives can be changed by assembly parameters in MACN11.
|
||||
In the configuration maintained by ISI these defaults match
|
||||
MACRO-11's except for the following:
|
||||
|
||||
.NLIST TTM ; [format listings for lpt output]
|
||||
.ENABL LC ; [don't fold lower case]
|
||||
|
||||
|
||||
|
||||
|
||||
Notes on MACN11 Version 3 Page 3
|
||||
|
||||
|
||||
|
||||
<< Language extensions >>
|
||||
|
||||
|
||||
.ASCII & .ASCIZ
|
||||
|
||||
MACN11 allows multiple expressions, rather than just one,
|
||||
within brackets. Expressions are delimited by commas.
|
||||
E.g., "<cr><lf>" can be written as "<cr,lf>".
|
||||
|
||||
|
||||
.ENABL & .DSABL
|
||||
|
||||
These verbs recognize two nonstandard operands:
|
||||
|
||||
NSF (Nonstandard features): Enabled by default.
|
||||
Enabling NSF allows use of MACN11's extended features.
|
||||
Disabling limits the acceptable source language to
|
||||
being strictly compatible with MACRO-11.
|
||||
|
||||
ISD (Internal Symbol Definitions): Disabled by default
|
||||
Enabling ISD includes definitions of internal symbols,
|
||||
as well as global symbols, in the object module output.
|
||||
These definitions allow generation of a symbol table
|
||||
for debuggers such as DDT-11.
|
||||
|
||||
HOV (Hexadecimal override): Disabled by default. If the
|
||||
current radix is 16 and HOV is enabled, then terms of
|
||||
expressions which begin with A-F are assumed to be hex
|
||||
numbers, rather than symbols. E.g.,
|
||||
|
||||
.ENABL HOV ; Enabling hex override causes
|
||||
MOV A,R0 ; this instruction to load 10. into
|
||||
; R0, rather than the address of a
|
||||
; word labelled A.
|
||||
|
||||
|
||||
.ENDM
|
||||
|
||||
Interior macro definitions within a nest can be terminated
|
||||
by a .ENDM whose operand is the name of an exterior
|
||||
definition.
|
||||
|
||||
|
||||
Hexadecimal numbers
|
||||
|
||||
Hex numbers, using the digits 0-9 and A-F, may be used via
|
||||
extensions of the existing radix control functions. .RADIX
|
||||
accepts 16 as a valid operand to set the current default
|
||||
radix, and temporary radix control includes "H" in addition
|
||||
to the standard "D", "O", and "B".
|
||||
|
||||
When using hexadecimal as the default radix it is normally
|
||||
necessary to prefix numbers beginning with A-F by a 0;
|
||||
|
||||
Notes on MACN11 Version 3 Page 4
|
||||
|
||||
|
||||
|
||||
otherwise they would be parsed as symbols. Use of .ENABL
|
||||
HOV eliminates this need at the cost of making symbols
|
||||
beginning with A-F inaccessible.
|
||||
|
||||
|
||||
Logical shift operator ("_")
|
||||
|
||||
An additional binary operator is recognized in expression
|
||||
evaluation. "a_b" is evaluated as "the value of a shifted
|
||||
left b bits". If b is negative, the term is shifted right.
|
||||
Both a and b may be any valid term, including a bracketed
|
||||
expression.
|
||||
|
||||
A common use for this operator is in defining symbolic
|
||||
values for bit masks. For example, "INTENA = 1_6" defines
|
||||
an interrupt enable mask as a 1 in bit 6.
|
||||
|
||||
|
||||
.PDP10
|
||||
|
||||
The ".PDP10" directive is recognized, but is ignored. This
|
||||
is for the sake of assembling Bliss-11 compiler output.
|
||||
|
||||
|
||||
|
||||
Predefined symbols
|
||||
|
||||
Symbols can be predefined by assembling their symbol table
|
||||
entries into MACN11. At present register names (R0-R7, SP,
|
||||
and PC) and ".MACN." are defined in this way. .MACN. is
|
||||
equated to the assembler's version number.
|
||||
|
||||
|
||||
Radix 50 terms in expressions: ^R
|
||||
|
||||
"^R" is recognized as a unary operator in expressions,
|
||||
indicating that the next three characters are to be
|
||||
converted to radix 50 format for use as a 16-bit value. Any
|
||||
character without a radix 50 equivalent is treated as a
|
||||
delimiter, and is taken as equivalent to trailing blanks in
|
||||
evaluating the term.
|
||||
|
||||
|
||||
.SBHED
|
||||
|
||||
A new directive, .SBHED, specifies a subheading; it
|
||||
functions as a conditional .PAGE followed by a .SBTTL. It
|
||||
skips to a new page unless the most recent listing output
|
||||
was a page skip, then outputs a standard page heading.
|
||||
.SBHED's operand field is included in the table of contents
|
||||
and in all page subheadings until another .SBHED or a .SBTTL
|
||||
is issued. The .SBHED directive itself is the first line
|
||||
listed below the new page heading.
|
||||
|
||||
Notes on MACN11 Version 3 Page 5
|
||||
|
||||
|
||||
|
||||
---------------- Operating Procedures -----------------
|
||||
|
||||
|
||||
|
||||
Operating procedures for MACN11 version 3 are nearly
|
||||
identical to MACRO-11's. The only differences are the following:
|
||||
|
||||
"=" and "_" are accepted as synonyms for "<".
|
||||
The /PA switch is accepted but is ignored.
|
||||
An additional switch, /FO, is available to specify
|
||||
the PDP-10 file format for object output.
|
||||
Cross references are pretty disgusting.
|
||||
|
||||
Details of these differences are included in the description
|
||||
below.
|
||||
|
||||
|
||||
|
||||
|
||||
MACN11 assembles one or more source files, normally
|
||||
producing two files: a relocatable object module and an assembly
|
||||
listing. Command string syntax is similar to MACRO-11's.
|
||||
|
||||
Object files normally are generated in packed format, with
|
||||
each PDP-11 word right-adjusted in a PDP-10 halfword. This
|
||||
format is standard for other utilities which may deal with these
|
||||
files (LNKX11, LINK11, FILEX, etc.).
|
||||
|
||||
|
||||
Command Input String
|
||||
|
||||
|
||||
When MACN11 is ready for a command it lists its name and
|
||||
version number on the user's terminal, then outputs a "*" on a
|
||||
new line. In return it expects the following sort of string:
|
||||
|
||||
|
||||
object,listing<source1,source2,...,sourcen
|
||||
|
||||
|
||||
"<" separates output file specifications from input specs. "="
|
||||
and "_" are equally acceptable.
|
||||
|
||||
Each field in the command string specifies a file name and
|
||||
may include optional switches. File names must conform to
|
||||
DEC conventions (6-byte file name, optional 3-byte
|
||||
extension). If the extension is omitted on any file name
|
||||
the assembler chooses a suitable default.
|
||||
|
||||
A PPN (project-programmer number) may be supplied where
|
||||
MACRO-11 would accept a UIC (user identification code).
|
||||
Under Tenex this is treated as a directory number. MACN11's
|
||||
source contains assembly parameters to allow it to accept
|
||||
|
||||
Notes on MACN11 Version 3 Page 6
|
||||
|
||||
|
||||
|
||||
PPNs in the formats used by CMU and Stanford.
|
||||
|
||||
|
||||
Object is normally a relocatable object module file, ready for
|
||||
input to LNKX11 or LINK-11. Its default extension is
|
||||
".OBJ". Absolute binary output, with default extension
|
||||
".BIN", can be generated by using ".ENABL ABS" in the source
|
||||
program, or by including a "/EN:ABS" switch in the command
|
||||
string.
|
||||
|
||||
Object file format may be specified with the "/FO" switch.
|
||||
"/FO:P" generates packed output (1 PDP-11 word per PDP-10
|
||||
halfword), and is the default. "/FO:I" forces image-mode
|
||||
output, with one 8-bit byte per PDP-10 word.
|
||||
|
||||
|
||||
Listing is an ASCII file with a default extension of ".LST".
|
||||
Cross references may be obtained by using a "/CRF" switch
|
||||
with the listing file; this generates a file with extension
|
||||
".CRF", which must be run through CREF. The resulting
|
||||
listing is terrible. It looks a little better if "/NL:SEQ"
|
||||
is also specified, but that doesn't cure the readability
|
||||
problems. In addition, not all references to symbols are
|
||||
recorded in the cross reference. All of these woes will be
|
||||
fixed by moving cross reference processing into MACN11; this
|
||||
will be done no later than version 5 of the assembler.
|
||||
|
||||
|
||||
Source files are in ASCII, with the following default extensions
|
||||
recognized by the assembler:
|
||||
|
||||
".M11", ".P11", ".MAC", blank
|
||||
|
||||
|
||||
Either the object file or the listing file, but not both,
|
||||
may be omitted. Any number of source files (except 0) may be
|
||||
used.
|
||||
|
||||
Notes on MACN11 Version 3 Page 7
|
||||
|
||||
|
||||
|
||||
------------- Assembler Generation Options --------------
|
||||
|
||||
|
||||
|
||||
The source for MACN11 contains a number of assembly
|
||||
parameters to allow customizing it for individual installations.
|
||||
Most, but not all, are clustered on a couple pages at the
|
||||
beginning. The most useful of these parameters, and their values
|
||||
in the ISI source, are . . .
|
||||
|
||||
|
||||
Name Default Value Meaning
|
||||
-------- ----------- ---------------------------------
|
||||
|
||||
CCLSW 0 1 => Generate CCL support
|
||||
|
||||
CMUSW 0 1 => Handle CMU PPNs
|
||||
in file names
|
||||
|
||||
STANSW 0 1 => Handle Stanford PPNs
|
||||
|
||||
PAGSIZ D54 Number of lines per page
|
||||
on listing output
|
||||
|
||||
ENDEF LCFLG+PNCFLG+REGFLG Default .ENABL modes; bit names
|
||||
are "xxxFLG", where "xxx" is an
|
||||
operand of .ENABL/.DSABL.
|
||||
|
||||
LDEF 777777-LLD-LME-LMEB-LTTM Default .LIST modes; bit names
|
||||
are "Lxxx", where "xxx" is an
|
||||
operand of .LIST/.NLIST.
|
||||
|
||||
|
||||
|
||||
Additional symbols can be predefined by assembling their
|
||||
definitions into the prototype symbol table which begins at
|
||||
location PERMST, near the end of the assembly. This table is
|
||||
kept in ascending order by the .RAD50 (mod 40) value of the
|
||||
symbol, which is equivalent to alphabetic order except for "."
|
||||
and "$". Entry format is . . .
|
||||
|
||||
XWD ; type-flags,value
|
||||
GENM40 N,A,M,E ; 1-6 characters
|
||||
|
||||
Type flags may be . . .
|
||||
|
||||
DEFSYM -- Symbol is defined
|
||||
REGSYM -- Symbol identifies a register
|
||||
GLBSYM -- Symbol is global (external if DEFSYM not set)
|
||||
|
||||
Notes on MACN11 Version 3 Page 8
|
||||
|
||||
|
||||
|
||||
--------- Internal Symbol Definitions ----------
|
||||
|
||||
|
||||
|
||||
When ISD is enabled, internal symbol definition entries
|
||||
When .ENABL ISD is in effect, internal symbol definition entries
|
||||
are included in the generated object module's global symbol
|
||||
dictionary. These are type 2 GSD entries, which are identified
|
||||
in appendix B (B.1.3) of the DOS/Batch Linker manual. Their
|
||||
format is:
|
||||
|
||||
|
||||
---------------------------------
|
||||
! Symbol !
|
||||
! Name !
|
||||
---------------------------------
|
||||
! 2 ! Flags !
|
||||
---------------------------------
|
||||
! Value !
|
||||
---------------------------------
|
||||
|
||||
|
||||
The symbol name is two words in .RAD50 format.
|
||||
|
||||
The flag byte currently has only one bit defined: Bit 0 is set if
|
||||
the symbol is a register name. All undefined bits are set to 0.
|
||||
|
||||
The value is identical to that field in global symbol name (type
|
||||
4) entries: It is the symbol's offset from the start of the csect
|
||||
identified by the most recent type 1 (csect name) entry. ISD
|
||||
values are absolute if they follow the absolute csect's type 1
|
||||
entry.î
|
||||
@ -210,6 +210,7 @@
|
||||
- LUSER, request help from registered list of logged-in users.
|
||||
- MBXLOC, lock a mailbox.
|
||||
- MACDMP, standalone program loader/dumper for DECtape.
|
||||
- MACN11, PDP-11 cross assembler.
|
||||
- MACN80, Z80 cross assembler.
|
||||
- MACRO-10, DEC assembler.
|
||||
- MACSYMA, symbolic manipulation system.
|
||||
|
||||
BIN
src/decsys/macn11.hdr
Normal file
BIN
src/decsys/macn11.hdr
Normal file
Binary file not shown.
BIN
src/decsys/macn11.mac
Normal file
BIN
src/decsys/macn11.mac
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user