<<------------------------------------------------------------>>        00005000
<<                                                            >>        00010000
<<                                                            >>        00015000
<<     iii   n    n  ccccc  l           aa     rrrrrr  qqqqqq >>        00020000
<<      i    nn   n  c      l          a  a    r    r  q    q >>        00025000
<<      i    n n  n  c      l         aaaaaa   rrrrrr  q    q >>        00030000
<<      i    n  n n  c      l         a    a   r r     q  q q >>        00035000
<<      i    n   nn  c      l         a    a   r  r    qqqqqq >>        00040000
<<     iii   n    n  ccccc  llllll    a    a   r   r       q  >>        00045000
<<                                                            >>        00050000
<<                                                            >>        00055000
<<                                                            >>        00060000
<<                        inclarq                             >>        00065000
<<                                                            >>        00070000
<<          alternate que  addressing  modes for mpev         >>        00075000
<<                                                            >>        00080000
<<------------------------------------------------------------>>        00085000
                                                                        00090000
                                                                        00095000
                                                                        00100000
                                                                        00105000
                                                                        00110000
                                                                        00115000
                                                                        00120000
<< part 1:  direct   addressing   for   the  que  head        >>        00125000
                                                                        00130000
                                                                        00135000
                                                                        00140000
                                                                        00145000
                                                                        00150000
                                                                        00155000
<<  this define will set db to the base of the drq     >>               00160000
<<  this should only be done if disabled or pdisabled  >>               00165000
define                                                                  00170000
   dbtodrq =                                                            00175000
      tos := 0;                                                         00180000
      tos := absolute(2) + drq'dst'bkadr;                               00185000
      assemble( ldea );                                                 00190000
      assemble( xchd ); << exchange db to base of drq >>                00195000
      dbsave := tos;    << remember where db was >>                     00200000
      #;                                                                00205000
                                                                        00210000
equate                                                                  00215000
                                                                        00220000
    drqdst            = 56,       << dst # for drq >>                   00225000
    drq'dst'bkadr     =  drqdst * 4 + 2,                                00230000
                                                                        00235000
    aqh'totent'index  =  0,                                             00240000
    aqh'entsize'index =  1,                                             00245000
    aqh'prient'index  =  2,                                             00250000
    aqh'imppcb'index  =  3,                                             00255000
    aqh'freehead'index=  4,                                             00260000
    aqh'freetail'index=  5,                                             00265000
    aqh'maxinuse'index=  6,                                             00270000
    aqh'curinuse'index=  7,                                             00275000
    aqh'ovrflows'index=  8,                                             00280000
    aqh'reqcount'index=  9,                                             00285000
    aqh'reqcounu'index=  10,                                            00290000
    aqh'dishead'index =  11,                                            00295000
    aqh'distail'index =  12,                                            00300000
    aqh'serwqhead'index =13,                                            00305000
    aqh'flags'index   =  14,                                            00310000
    aqh'header'size   =  16;                                            00315000
                                                                        00320000
                                                                        00325000
                                                                        00330000
integer                                                                 00335000
                                                                        00340000
    aqh'tot'ent =   db + dqh'totent'index,  << total # of entries  >>   00345000
    aqh'ent'size=   db + dqh'entsize'index, << entry size          >>   00350000
    aqh'pri'ent =   db + dqh'prient'index,  << # of primary entries >>  00355000
    aqh'imp'pcb =   db + dqh'imppcb'index,  << impeded pcb         >>   00360000
    aqh'freehead=   db + dqh'freehead'index,<< free entry list pntr >>  00365000
    aqh'freetail=   db + dqh'freetail'index,<< free list tail pntr >>   00370000
    aqh'max'nuse=   db + dqh'maxinuse'index,<< max ques ever used >>    00375000
    aqh'cur'nuse=   db + dqh'curinuse'index,<< current ques used  >>    00380000
    aqh'ovrflows=   db + dqh'ovrflows'index,<< number of overflows >>   00385000
    aqh'reqcount=   db + dqh'reqcount'index,<< total of all request >>  00390000
    aqh'reqcounu=   db + dqh'reqcounu'index,<< total of all request >>  00395000
    aqh'disahead=   db + dqh'dishead'index, << head of disabled que >>  00400000
    aqh'disatail=   db + dqh'distail'index, << tail of disabled que >>  00405000
    aqh'flags=      db + dqh'flags'index,                               00410000
    aqh'serwqhead=  db + dqh'serwqhead'index;                           00415000
define                                                                  00420000
    aqh'actserwrflag = (0:1)#,                                          00425000
    aqh'maxserqfield=(8:8)#,                                            00430000
    aqh'maxserwq=aqh'flags.aqh'maxserqfield#;                           00435000
                                                                        00440000
                                                                        00445000
                                                                        00450000
                                                                        00455000
                                                                        00460000
                                                                        00465000
                                                                        00470000
                                                                        00475000
                                                                        00480000
<<   part 2:  direct  indexed addressing for the que element  >>        00485000
                                                                        00490000
                                                                        00495000
                                                                        00500000
                                                                        00505000
                                                                        00510000
logical array                                                           00515000
    drq'flags'word(*)   = db + 0,                                       00520000
    drq'pcb'word(*)     = db + 11;                                      00525000
integer array                                                           00530000
    drq'urgclas'word(*) = db + 1,                                       00535000
    drq'fre'lnk'word(*) = db + 1,                                       00540000
    drq'ldev'word(*)    = db + 2,                                       00545000
    drq'qmisc'word(*)   = db + 3,                                       00550000
    drq'bufdst'word(*)  = db + 4,                                       00555000
    drq'bufadr'word(*)  = db + 5,                                       00560000
    drq'func'word(*)    = db + 6,                                       00565000
    drq'count'word(*)   = db + 7,                                       00570000
    drq'parm1'word(*)   = db + 8,                                       00575000
    drq'parm2'word(*)   = db + 9,                                       00580000
    drq'status'word(*)  = db + 10,                                      00585000
    drq'prevq'word(*)   = db + 12,                                      00590000
    drq'nextq'word(*)   = db + 13,                                      00595000
    drq'segid1'word(*)  = db + 14,                                      00600000
    drq'segid2'word(*)  = db + 15,                                      00605000
    drq'segdisp'word(*) = db + 16;                                      00610000
define                                                                  00615000
                                                                        00620000
    arqx'flags   =   drq'flags'word(drq'entry'index)#,                  00625000
    arqx'urgclas =   drq'urgclas'word(drq'entry'index)#,                00630000
    arqx'freelink=   drq'fre'lnk'word(drq'entry'index)#,                00635000
    arqx'ldev    =   drq'ldev'word(drq'entry'index)#,                   00640000
    arqx'qmisc   =   drq'qmisc'word(drq'entry'index)#,                  00645000
    arqx'bufdst  =   drq'bufdst'word(drq'entry'index)#,                 00650000
    arqx'unitfnc =   drq'func'word(drq'entry'index)#,                   00655000
    arqx'count   =   drq'count'word(drq'entry'index)#,                  00660000
    arqx'parm1   =   drq'parm1'word(drq'entry'index)#,                  00665000
    arqx'parm2   =   drq'parm2'word(drq'entry'index)#,                  00670000
    arqx'stat    =   drq'status'word(drq'entry'index)#,                 00675000
    arqx'pcb     =   drq'pcb'word(drq'entry'index)#,                    00680000
    arqx'prevq   =   drq'prevq'word(drq'entry'index)#,                  00685000
    arqx'nextq   =   drq'nextq'word(drq'entry'index)#,                  00690000
    arqx'segid1  =   drq'segid1'word(drq'entry'index)#,                 00695000
    arqx'segid2  =   drq'segid2'word(drq'entry'index)#,                 00700000
    arqx'segdisp =   drq'segdisp'word(drq'entry'index)#;                00705000
                                                                        00710000
                                                                        00715000
define                                                                  00720000
                                                                        00725000
       << these field defintion should agree with inclobj >>            00730000
   arqx'segid'type     = arqx'segid1.(0:4)#,    << type of segid >>     00735000
   arqx'segid'cstblk   = arqx'segid1.(4:12)#,   << index into cstblk >> 00740000
   arqx'segid'numfield = arqx'segid2#;          << appropriate value >> 00745000
                                                                        00750000
                                                                        00755000
define                                                                  00760000
                                                                        00765000
    arqx'dbrel   =   arqx'bufdst.(0:1)#,    << 1 => io is db rel. >>    00770000
    arqx'buf'dstn=   arqx'bufdst.(1:15)#,   <<  dst number only >>      00775000
    arqx'unit    =   arqx'unitfnc.(0:8)#,   << unit # on controller >>  00780000
    arqx'func    =   arqx'unitfnc.(8:8)#,   << function requested  >>   00785000
                                                                        00790000
                                                                        00795000
    arqx'abort   =   arqx'flags.(0:1)#,     << drz is to be aborted >>  00800000
    arqx'mmreq   =   arqx'flags.(1:1)#,     << segment xfer req. >>     00805000
    arqx'diag    =   arqx'flags.(2:1)#,     << a diagnostic request >>  00810000
    arqx'sbuf    =   arqx'flags.(3:1)#,     << req uses sbufs  >>       00815000
    arqx'iowake  =   arqx'flags.(4:1)#,     << wake caller when done >> 00820000
    arqx'blocked =   arqx'flags.(5:1)#,     << req waited in attachio>> 00825000
    arqx'done    =   arqx'flags.(6:1)#,     << req is done  >>          00830000
    arqx'datafrzn=   arqx'flags.(7:1)#,     << data is frozen in mem >> 00835000
    arqx'mamerr  =   arqx'flags.(8:1)#,     << make present error >>    00840000
    arqx'preq    =   arqx'flags.(9:1)#,     << req is queued      >>    00845000
    arqx'sfail   =   arqx'flags.(10:1)#,    << start io failed   >>     00850000
    arqx'pfail   =   arqx'flags.(11:1)#,    << a powerfail occured >>   00855000
    arqx'cur'req =   arqx'flags.(12:1)#,    << 1=current request   >>   00860000
    arqx'disable =   arqx'flags.(13:1)#,    << request is disabled  >>  00865000
    arqx'is'ldrq =   arqx'flags.(14:1)#,    << request is ldr>><<*7603>>00870000
    arqx'inlocal =   arqx'flags.(15:1)#,    << dst in local >> <<*7603>>00875000
    serwqflag' =(8:1)#,                                                 00880000
    arqx'on'freelist=arqx'pcb.(0:1)#,       <<1 means on free list  >>  00885000
    arqx'serwq  = arqx'flags.serwqflag'#;                               00890000
                                                                        00895000
                                                                        00900000
                                                                        00905000
                                                                        00910000
                                                                        00915000
                                                                        00920000
<< part 3:  direct  que element addressing                        >>    00925000
                                                                        00930000
                                                                        00935000
                                                                        00940000
                                                                        00945000
                                                                        00950000
<<  while disabled or pdisabled db should be set to a que element >>    00955000
<<  with the define: setdb'que.  each word of the que can then be >>    00960000
<<  addressed directly without indexing.  when done  db should be >>    00965000
<<  restored usually to sysdb with the define:  setdb'sys         >>    00970000
                                                                        00975000
<<  this include must follow  the  incldrq include                >>    00980000
                                                                        00985000
logical array  arq(*) = db;    << db  at the table entry desired  >>    00990000
                                                                        00995000
                                                                        01000000
logical                                                                 01005000
                                                                        01010000
    arq'flags   =   db+drq'flags'index,                                 01015000
    arq'urgclas =   db+drq'urgclas'index,                               01020000
    arq'freelink=   db+drq'fre'lnk'index,                               01025000
    arq'ldev    =   db+drq'ldev'index,                                  01030000
    arq'qmisc   =   db+drq'qmisc'index,                                 01035000
    arq'bufdst  =   db+drq'bufdst'index,                                01040000
    arq'bufadr  =   db+drq'bufadr'index,                                01045000
    arq'unitfnc =   db+drq'func'index,                                  01050000
    arq'count   =   db+drq'count'index,                                 01055000
    arq'parm1   =   db+drq'parm1'index,                                 01060000
    arq'parm2   =   db+drq'parm2'index,                                 01065000
    arq'stat    =   db+drq'status'index,                                01070000
    arq'pcb     =   db+drq'pcb'index,                                   01075000
    arq'prevq   =   db+drq'prevq'index,                                 01080000
    arq'nextq   =   db+drq'nextq'index,                                 01085000
    arq'segid1  =   db+drq'segid1'index,                                01090000
    arq'segid2  =   db+drq'segid2'index,                                01095000
    arq'segdisp =   db+drq'segdisp'index;                               01100000
                                                                        01105000
                                                                        01110000
define                                                                  01115000
                                                                        01120000
       << these field defintion should agree with inclobj >>            01125000
   arq'segid'type     = arq'segid1.(0:4)#,    << type of segid >>       01130000
   arq'segid'cstblk   = arq'segid1.(4:12)#,   << index into cstblk >>   01135000
   arq'segid'numfield = arq'segid2#;          << appropriate value >>   01140000
                                                                        01145000
                                                                        01150000
define                                                                  01155000
                                                                        01160000
    arq'dbrel   =   arq'bufdst.(0:1)#,    << 1 => io is db rel. >>      01165000
    arq'buf'dstn=   arq'bufdst.(1:15)#,   <<  dst number only >>        01170000
    arq'unit    =   arq'unitfnc.(0:8)#,   << unit # on controller >>    01175000
    arq'func    =   arq'unitfnc.(8:8)#,   << function requested  >>     01180000
                                                                        01185000
                                                                        01190000
    arq'abort   =   arq'flags.(0:1)#,     << arq is to be aborted >>    01195000
    arq'mmreq   =   arq'flags.(1:1)#,     << segment xfer req. >>       01200000
    arq'diag    =   arq'flags.(2:1)#,     << a diagnostic request >>    01205000
    arq'sbuf    =   arq'flags.(3:1)#,     << req uses sbufs  >>         01210000
    arq'iowake  =   arq'flags.(4:1)#,     << wake caller when done >>   01215000
    arq'blocked =   arq'flags.(5:1)#,     << req waited in attachio>>   01220000
    arq'done    =   arq'flags.(6:1)#,     << req is done  >>            01225000
    arq'datafrzn=   arq'flags.(7:1)#,     << data is frozen in mem >>   01230000
    arq'mamerr  =   arq'flags.(8:1)#,     << make present error >>      01235000
    arq'preq    =   arq'flags.(9:1)#,     << req is queued      >>      01240000
    arq'sfail   =   arq'flags.(10:1)#,    << start io failed   >>       01245000
    arq'pfail   =   arq'flags.(11:1)#,    << a powerfail occured >>     01250000
    arq'cur'req =   arq'flags.(12:1)#,    << 1=current request      >>  01255000
    arq'disable =   arq'flags.(13:1)#,    << request is disabled  >>    01260000
    arq'is'ldrq =   arq'flags.(14:1)#,    << request is ldr  >><<*7603>>01265000
    arq'inlocal =   arq'flags.(15:1)#,    << dst in local   >> <<*7603>>01270000
    arq'on'freelist=arq'pcb.(0:1)#,       << 1 means on free list  >>   01275000
    arq'serwq  = arq'flags.serwqflag#;                                  01280000
                                                                        01285000
                                                                        01290000
<<------------------------------------------------------------>>        01295000
<<                      end   inclarq                         >>        01300000
<<                                                            >>        01305000
<<          alternate que  addressing  modes for mpev         >>        01310000
<<                                                            >>        01315000
<<------------------------------------------------------------>>        01320000
