         DEF      SSDAT:            PATCHING DEF
SSDAT:   RES
*
         SYSTEM   UTS
***********************************************************************
*
*M*      SSDAT - SCHEDULER AND SWAPPER DATA AREA
*
***********************************************************************
*************************************
         DEF      S:BUIS            NUMBER OF BATCH USERS ACTIVE
         DEF      S:BFIS            NUMBER OF BATCH FILES (JOBS)
         DEF      S:MPRET           * RETURN STACK FOR MULTI-PROCESSORS
*,*                                 WAITING TO BE PROCESSED
         DEF      S:HIR             SCHEDULER RE-ENTRANCY COUNTER
         DEF      S:CUIS            CURRENT NO OF USERS IN SYSTEM
         DEF      S:OUIS            # OF ONLINE USERS IN SYSTEM
         DEF      S:GUIS            # OF GHOST USERS IN SYSTEM
         DEF      S:MBSF            MBS ACTIVATE FLAG
         DEF      S:SIP             SWAP IN PROGRESS FLAG
         DEF      S:USID            NEXT BATCH SYSID
         DEF      ONLN              VALUE DEF FOR ONLINE BIT
         DEF      GJOB              VALUE DEF FOR GHOST BIT
         DEF      S:OPC             WORKING VAL FOR PROT CT
         DEF      SL:OPC            REFRESH VALUE FRO S:OPC
         DEF      SL:BIOTA          * BATCH I/O TIME ALLOWANCE
         DEF      SL:GIOTA          * GHOST I/O TIME ALLOWANCE
         DEF      SL:OIOTA          * ONLINE I/O TIME ALLOWANCE
         DEF      S:CUP
         DEF      SH:PINC
         DEF      S:RTIR
         DEF      S:PRIODEC
         DEF      S:RTCORE
         DEF      S:RTUN
         DEF      S:ISUN
         DEF      S:ISUNF
         DEF      S:SEVF
         DEF      S:FSEVF
         DEF      SCBPOOLIM
         DEF      SPOOL
         DEF      BUFLIMS
         DEF      MPOOLIM
         DEF      SL:SQPB           PRIO BOOST FOR INTERRUPT AFTER SQNT
         DEF      SL:SQNT           THRESHOLD AT WHICH TO EXPEDITE USER
         DEF      SB:RTUS           USER NO FOR RT USER
         DEF      S:MAPCW           CONTROL WORD TO LOAD MAP IMAGE
         DEF      S:ACCW            CONTROL WORD TO LOAD ACCESS CONTROL
         REF      SMUIS             LENGTH OF USER TABLES
         REF      JOVVP
         REF      JCMAP
         REF      JJAC
         REF      NPMC
         REF      CPOOL
         REF      MPOOL
         REF      RECOVER0
         REF      CPOOLEND
         REF      :DP
         DEF      NSWAP             NO. OF SWAPPERS IN SYSTEM.
GJOB     EQU      X'40'             IN HIGH ORDER BYTE OF JIT
*
*        THESE CELLS TELL THE SLAVE PROCESSORS WHERE TO RETURN TO
*        AFTER MAPPING  (ONE PER PROCESSOR)
*
S:MPRET  RES      4
ONLN     EQU      X'80'             IN HIGH ORDER BYTE OF JIT
S:HIR    DATA     0                 HI-PRI READY TO RUN COUNT
S:CUIS   DATA     0                 CURRENT # OF USERS IN TEH SYSTEM
S:BUIS   DATA     0                 # OF BATCH JOBS RUNNING
S:OUIS   DATA     0
S:GUIS   DATA     0
S:BFIS   DATA     0                 # OF JOBS IN BATCH STREAM
S:SIP    DATA     0                 SWAP IN PROGRESS
S:USID   DATA     SMUIS             BATCH SYSID
S:OPC    DATA     4                 WORKING VALUE FOR OVERLAY PROTECTION COUNTER
SL:OPC   DATA     4                 REFRESH VALUE FOR S:OPC
S:PFNI   DATA     5                 PROCESSOR NORMALIZATION INTERVAL
SL:PFNI  DATA     5                 REFRESH VALUE FOR INTERVAL
*                                   (IN MINUTES)
         DEF      S:PFNI,SL:PFNI
SB:RTUS  DATA     0                 REAL TIME USER NUMBER FOR
*                                   USER IN CORE AND HIGHER IN PRIORITY
*                                   THAN CURRENT USER.
*
*
S:ISUN   DATA     3                 IN-SWAP USER NO.
S:ISUNF  DATA     0
S:SEVF   DATA     0
S:FSEVF  DATA     0                 FAILED SWAP EVENT COUNT
         PAGE
*
*   MISC STUFF
*
S:MBSF   DATA     0
SPOOL    DATA     0
S:PRIODEC DATA    1                 PRIORITY DECREMENT
S:CUP    DATA     X'FF'             CURRENT USER PRIORITY
S:RTIR   DATA     X'00000000'       REAL TIME IN AND READY FLAG
S:RTCORE DATA     0                 TOTAL SIZE OF R-T USERS LOCKED IN
*                                    CORE
S:RTUN   DATA     0                 REAL TIME USER #
*
*        THE FOLLOWING IOTA'S MUST REMAIN IN THIS ORDER
*        BECAUSE IOQM EXPECTS THEM TO BE THAT WAY
*
         SPACE
SL:BIOTA DATA     2                 * DEFAULTS ARE ALL 2
SL:GIOTA DATA     2                 * THESE ARE SETTABLE BY CONTROL
SL:OIOTA DATA     2                 * HOWEVER
SL:SQPB  DATA     1                 BOOST ONE NOTCH BETWEEN SL:SQNT
*                                   AND SL:SQUAN
SL:SQNT  DATA     150               300 MS
*                                   TO ENFORCE CORE QUANTUM FOR I/O
         PAGE
         DEF      S:BADFLG
S:BADFLG DATA     0
*
*        S:BADFLG IS CELL CONTAINING ONE BIT FLAGS
*        REPRESENTING THE OCCURRENCE OF EVENTS WHICH
*        MAY BE OF INTEREST IN THE ANALYSIS OF A CRASH DUMP
*
*        BIT      MEANING
*        ---      -------
*         0       REAL-TIME ACTIVITY; INTERRUPTS CONNECTED
*         1       REAL-TIME LOCK IN CORE
*         2       REAL-TIME LOCK IN CORE ABORT
*         3       SINGLE USER ABORT
*
*        ALL OTHERS CURRENTLY UNDEFINED AND SHOULD REMAIN ZERO
*
         PAGE
         BOUND    8
*
BUFLIMS  EQU      %
SCBPOOLIM EQU     0
         DATA     CPOOL,CPOOLEND
MPOOLIM  EQU      1
         DATA     MPOOL,CPOOL-1
*
*        MEMORY MAP CONTROL WORDS
*              INITIALIZED BY BOOTSUBR
*
S:MAPCW  GEN,15,17   0,JCMAP
         GEN,8,7,8,9 0,0,JOVVP,0
S:ACCW   GEN,15,17   0,JJAC
         GEN,8,7,8,9 0,0,JOVVP,0
SNSTS    EQU      31
*
* Q HEADS AND TAILS
*
         DEF      SB:HQ,SB:TQ
         REF      MING
         BOUND    8
SB:HQ    DATA     0,0,0,0,0,0,0
         GEN,16,8,8 0,MING,0
         BOUND    8
SB:TQ    DATA     0,0,0,0,0,0,0
         GEN,16,8,8 0,SMUIS,0
         DEF      REG1PSD
NRSRC    EQU      17
SB:RQ    EQU      %
         BYTAB    NRSRC
         DEF      SB:RQ
SB:RQT   EQU      %
         BYTAB    NRSRC
         DEF      SB:RQT            TAIL OF RESOUCE SUBQUEUE
         REF      REG1
         DEF      S:EVF
S:EVF    DATA     0                 EVENT RE-ENTRANCY COUNTER
         BOUND 8
         DEF      REGIPSD
         REF      T:IOREG           ENTRYPOINT IN SSS
REGIPSD  DATA     0,0
         GEN,12,20 X'004',T:IOREG   MASTER,MAPPED AT T:IOREG
         DATA     X'17000000'       DISABLED,WK=01
REG1PSD  DATA     0,0
         GEN,12,20  X'004',REG1     MASTER,MAPPED
         DATA     X'17000000'       DISABLES
NSWAP    DATA     1                 NO. OF SWAPPERS IN SYSTEM
*                                   (ONE AT T:GJOBSTRT OF STARTER GHOST)
         PAGE
*
*
*        SITUATIONAL PRIORITY INCREMENTS
*
*
SH:PINC  DATA,2   0                 COMPUTE
         DATA,2   3                 SPECIAL COMPUTE
         DATA,2   2                 I/O COMPLETE
         DATA,2   6                 INTERACTIVE
         DATA,2   4                 TERMINAL OUTPUT CONT
         DATA,2   3                 RESOURCE UNBLOCK
         DEF      S:OFFRF           OFFLINE REMOVE FLAG
         DEF      S:OFFRF:
S:OFFRF: EQU      S:OFFRF
S:OFFRF  DATA     0                 NOT ZERO => ONLINE REMOVE
         DEF      S:LAST
S:LAST   EQU      %
         END

