PCRMonitorDefs.mesa
Copyright Ó 1990 by Xerox Corporation. All rights reserved.
Peter B. Kessler, April 9, 1990 3:49:01 pm PDT
A description of PCR's monitor lock structure.
Transliterated from /pseudo/xrhome/2�.X/INCLUDE/xr.
How do I keep this in sync? Bleah!
DIRECTORY
TargetArchitecture;
PCRMonitorDefs: CEDAR DEFINITIONS ~ {
MonitorLock: TYPE ~ MACHINE DEPENDENT RECORD [
waitersQueue: WaitersQueueRep,
holder: Thread,
pad: TargetArchitecture.Contents
because Mimosa thinks MonitorLocks are 4 words long.
];
WaitersQueueRep: TYPE ~ MACHINE DEPENDENT RECORD [
generalSpinLock: GeneralSpinLockRep,
tail: Thread
];
GeneralSpinLockRep: TYPE ~ MACHINE DEPENDENT RECORD [
locked: LockBit
];
LockBit: TYPE ~ TargetArchitecture.Contents;
Thread: TYPE ~ TargetArchitecture.Contents;
IMPORTANT NOTE:
compiler and other runtime support assumes every data structure can be initialized to zeroes! And the claim here is that a zero is a zero is a zero, regardless of architecture.
nullHolder: Thread ~ TargetArchitecture.zeroContents;
}.