MipsLParms.mesa
Copyright Ó 1986, 1987, 1991 by Xerox Corporation. All rights reserved.
Russ Atkinson (RRA) January 29, 1988 2:54:01 pm PST
David Lai November 13, 1991 0:01 am GMT
MachineParms: DEFINITIONS = {
These definitions cover the MIPS Little-endian architecture.
BitOrder: TYPE = {msBit, lsBit};
msBit => bit N is more significant than bit N+1 in a word
(PrincOps, Dragon, Motorola 680x0, IBM 360, Sparc)
lsBit => bit N+1 is more significant than bit N in a word
(PDP-11, VAX, Intel 80x86, DEC)
WordOrder: TYPE = {msWord, lsWord};
msWord => word N is more significant than word N+1 in multi-word arithmetic
lsWord => word N+1 is more significant than word N in multi-word arithmetic
bitOrder: BitOrder = lsBit;
wordOrder: WordOrder = lsWord;
bitsPerAU: NAT = 8; -- AU = "addressing unit"
logBitsPerAU: NAT = BITS[[0..bitsPerAU)];
bitsPerByte: NAT = 8;
maxByte: NAT = 0FFh;
bitsPerChar: NAT = 8;
maxChar: NAT = 0FFh;
logBitsPerChar: NAT = BITS[[0..bitsPerChar)];
newLineChar: CHAR = 012C; -- UNIX convention
bitsPerWord: NAT = 32; -- bits per word (native arithmetic)
maxWord: CARD = 0FFFFFFFFh;
logBitsPerWord: NAT = 5;
bitsPerLongWord: NAT = 32;
maxLongWord: CARD = 0FFFFFFFFh;
logBitsPerLongWord: NAT = 5;
bitsPerReal: NAT = 32;
For BITS[REAL] on the target.
bitsPerPtr: NAT = 32;
For pointers into local and global frames.
bitsPerLongPtr: NAT = 32;
For all other pointers.
bitsPerPort: NAT = 2*bitsPerWord; -- obsolete!
bitsPerProc: NAT = 32;
bitsPerProcess: NAT = wordsPerProcess*bitsPerWord;
bitsPerProgram: NAT = bitsPerWord;
bitsPerRef: NAT = 32;
bitsPerSignal: NAT = bitsPerProc;
wordsPerProcess: NAT = 2;
processNil: ARRAY [0..wordsPerProcess) OF CARD32 = ALL[0];
wordsPerCondVar: NAT = 6;
bitsPerCondVar: NAT = wordsPerCondVar*bitsPerWord;
condVarInit: ARRAY [0..wordsPerCondVar) OF CARD32 = ALL[0];
wordsPerMonLock: NAT = 4;
bitsPerMonLock: NAT = wordsPerMonLock*bitsPerWord;
monLockInit: ARRAY [0..wordsPerMonLock) OF CARD32 = ALL[0];
bitsPerStringBound: NAT = 16;
StringBody has fields length & maxlength which must be unsigned[bitsPerStringBound]. STRING = POINTER TO StringBody.
TEXT has fields length & maxlength which must be of type [0..2**bitsPerStringBound-1), and the fields must occupy bitsPerStringBound bits each.
bitsPerLink: NAT = bitsPerPtr;
This length is used for imports/exports links.
fastBytes: BOOL = TRUE;
TRUE iff there is fast random access to bytes
packedFields: BOOL = TRUE;
PackedBitCount: TYPE = [1..bitsPerLongWord];
packedFieldSize: ARRAY PackedBitCount OF NAT = [
01, 02, 04, 04, 08, 08, 08, 08,
16, 16, 16, 16, 16, 16, 16, 16,
32, 32, 32, 32, 32, 32, 32, 32,
32, 32, 32, 32, 32, 32, 32, 32];
Alignments: ARRAY AlignmentIndex OF NAT = [8, 16, 32, 64];
AlignmentIndex: TYPE = [0..3];
}.