|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - download
Length: 6144 (0x1800) Types: Ada Source Notes: 03_class, FILE, R1k_Segment, e3_tag, seg_03bdc4
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000 └─ ⟦cfc2e13cd⟧ »Space Info Vol 2« └─⟦this⟧
-- Copyright 1986,1987,1988 Verdix Corporation WITH System; USE System; WITH V_I_Types; WITH V_I_Sema; WITH V_I_Time; WITH V_I_Timeop; WITH V_Tas; PACKAGE BODY V_Sema IS PRAGMA Suppress (All_Checks); PRAGMA Suppress (Exception_Tables); Priority_Inheritance_Enabled : Boolean; PRAGMA Interface_Name (Priority_Inheritance_Enabled, "PRIORITY_INHERITANCE_ENABLED"); -- -- Kernel semaphore support services -- PROCEDURE Krn_Suspend (S : V_I_Sema.A_Semaphore); PRAGMA Interface (Ada, Krn_Suspend); PRAGMA Interface_Name (Krn_Suspend, "KRN_SUSPEND"); FUNCTION Krn_Timed_Suspend (S : V_I_Sema.A_Semaphore; Timeout : Duration) RETURN Boolean; PRAGMA Interface (Ada, Krn_Timed_Suspend); PRAGMA Interface_Name (Krn_Timed_Suspend, "KRN_TIMED_SUSPEND"); PROCEDURE Krn_Resume (S : V_I_Sema.A_Semaphore); PRAGMA Interface (Ada, Krn_Resume); PRAGMA Interface_Name (Krn_Resume, "KRN_RESUME"); -- -- Time operators -- FUNCTION "+" (Left : V_I_Types.Time_T; Right : V_I_Types.Time_T) RETURN V_I_Types.Time_T RENAMES V_I_Timeop."+"; FUNCTION "-" (Left : V_I_Types.Time_T; Right : V_I_Types.Time_T) RETURN Duration RENAMES V_I_Timeop."-"; FUNCTION "<=" (Left : V_I_Types.Time_T; Right : V_I_Types.Time_T) RETURN Boolean RENAMES V_I_Timeop."<="; -- -- Support services from the archive semaphore routines -- FUNCTION Prio_Inherit_Conditional_Enter (S : V_I_Sema.A_Semaphore) RETURN Boolean; PRAGMA Interface (Ada, Prio_Inherit_Conditional_Enter); PRAGMA Interface_Name (Prio_Inherit_Conditional_Enter, "PRIO_INHERIT_CONDITIONAL_ENTER"); PROCEDURE Prio_Inherit_Leave (S : V_I_Sema.A_Semaphore); PRAGMA Interface (Ada, Prio_Inherit_Leave); PRAGMA Interface_Name (Prio_Inherit_Leave, "PRIO_INHERIT_LEAVE"); -- This routine is called to get a semaphore but will not wait if -- the semaphore is blocked. -- The success or failure of the enter is returned as a boolean. FUNCTION Conditional_Enter (S : V_I_Sema.A_Semaphore) RETURN Boolean IS Result : Boolean; BEGIN IF Priority_Inheritance_Enabled THEN RETURN Prio_Inherit_Conditional_Enter (S); END IF; V_Tas.Test_And_Set (S.Flag'Address, Result); RETURN Result; END Conditional_Enter; PRAGMA Inline_Only (Conditional_Enter); -- This routine is called to get a semaphore. It blocks until it -- has it. PROCEDURE Enter (S : V_I_Sema.A_Semaphore) IS BEGIN LOOP EXIT WHEN Conditional_Enter (S); Krn_Suspend (S); END LOOP; END Enter; PRAGMA Inline_Only (Enter); -- This routine is called upon exiting a semaphore region in user code. PROCEDURE Leave (S : V_I_Sema.A_Semaphore) IS BEGIN IF Priority_Inheritance_Enabled THEN Prio_Inherit_Leave (S); RETURN; END IF; S.Flag := V_I_Types.Test_And_Set_False; IF V_I_Types."=" (S.Others_Waiting, V_I_Types.Test_And_Set_True) THEN Krn_Resume (S); END IF; END Leave; PRAGMA Inline_Only (Leave); END V_Sema;
nblk1=5 nid=0 hdr6=a [0x00] rec0=20 rec1=00 rec2=01 rec3=04c [0x01] rec0=16 rec1=00 rec2=02 rec3=084 [0x02] rec0=03 rec1=00 rec2=05 rec3=00e [0x03] rec0=1f rec1=00 rec2=03 rec3=020 [0x04] rec0=0d rec1=00 rec2=04 rec3=000 tail 0x21739ba14856574769d70 0x489e0066482863c01