-- VMMapLog.mesa (last edited by: McJones on: August 16, 1979 10:42 PM)
VMMapLog: DEFINITIONS =
BEGIN
-- Map log: Pilot-to-Debugger communication of virtual memory backing storage binding
Descriptor: TYPE = MACHINE DEPENDENT RECORD [ -- must be allocated in permanently resident memory
self: Entry, -- description of virtual memory used by Pilot to access log
writer: EntryPointer, -- next entry Pilot will write
reader: EntryPointer, -- next entry debugger will examine
limit: EntryPointer, -- entry following last word of ring buffer
patchTable: LONG POINTER TO PatchTable];
-- Above writer, reader, and limit fields are relative to LOOPHOLE[LongPointerFromPage[self.page], EntryBasePointer]
EntryBasePointer: TYPE = LONG BASE POINTER TO RECORD [UNSPECIFIED];
EntryPointer: TYPE = EntryBasePointer RELATIVE POINTER [0..177777B] TO Entry;
Entry: TYPE = MACHINE DEPENDENT RECORD [ -- describe mapping of run of virtual pages with contiguous "backing storage"
page: CARDINAL, -- starting virtual page number
count: [1..4096], -- number of pages (12 bits)
writeProtected: BOOLEAN,
fill: [0..1], -- allow for expansion of variant tag
filePoint: SELECT kind: * FROM -- corresponding "backing storage"
nil => NULL, -- to nothing
alto31 => [ -- to Alto file with given fp, starting at given filePage
fp: AltoFP,
filePage: CARDINAL],
pilot31 => [ -- to contiguous disk addresses on Pilot-formatted model 31
vda: CARDINAL, -- ((track*2)+head)*12+sector
fid: PilotFID, -- fid of every label in run
filePage: CARDINAL], -- page number of first page in run
disk => [ -- to contiguous pages on Pilot physical volume
driveTag: CARDINAL, -- as returned by DiskChannel.GetDriveTag
diskPage: LONG CARDINAL, -- i.e. DiskChannel.DiskPageNumber
labelCheck: CARDINAL], -- as computed by FilePageLabel.LabelCheckSum
ENDCASE];
Pilot31Label: TYPE = MACHINE DEPENDENT RECORD [ -- must be consistent with Pilot’s FileInternal.Label
word0: UNSPECIFIED, -- don’t care
fid: PilotFID, -- constant for each page in a run
word3: UNSPECIFIED, -- don’t care
page: CARDINAL, -- increments for each page in a run
word5, word6, word7: UNSPECIFIED]; -- don’t care
PilotFID: TYPE = MACHINE DEPENDENT RECORD [UNSPECIFIED, UNSPECIFIED];
AltoFP: TYPE = MACHINE DEPENDENT RECORD [
serial: RECORD [UNSPECIFIED, UNSPECIFIED],
leaderDA: UNSPECIFIED];
-- Patch table: Debugger-to-Pilot communication of patches to (writeProtected) code segments
PatchTable: TYPE = MACHINE DEPENDENT RECORD [
limit: PatchTableEntryPointer, -- entry following last entry in use
maxLimit: PatchTableEntryPointer, -- entry following last allocated entry
entries: ARRAY [0..0) OF PatchTableEntry]; -- last entry with given address overrides
-- Above limit, maxLimit fields are relative to LOOPHOLE[@entries[0], PatchTableEntryBasePointer]
PatchTableEntryBasePointer: TYPE = LONG BASE POINTER TO RECORD [UNSPECIFIED];
PatchTableEntryPointer: TYPE = PatchTableEntryBasePointer RELATIVE POINTER [0..177777B] TO PatchTableEntry;
PatchTableEntry: TYPE = MACHINE DEPENDENT RECORD [
address: LONG POINTER,
value: UNSPECIFIED];
END.
LOG
Time: June 23, 1978 8:43 AMBy: McJonesAction: Created file
Time: July 12, 1978 3:39 PMBy: JohnssonAction: Counter proposal
Time: August 1, 1978 4:52 PMBy: McJonesAction: Refinements to BASE-RELATIVE types
Time: August 28, 1978 10:08 AMBy: McJonesAction: Added patch table
Time: August 16, 1979 10:42 PMBy: McJonesAction: Added writeProtected, disk variant to Entry