*DECK CSCPNQ USETEXT TEXTCS USETEXT TXTAPSS PROC CSCPNQ ((NACN), MSGFLAG); # TITLE CSCPNQ - PURGE NOP QUEUE. # BEGIN # CSCPNQ # # ** CSCPNQ - PURGE NOP QUEUE. * * D. G. DEPEW. 82/05/28. * * THIS PROCEDURE DELETES ALL WAITING BLOCK QUEUE (*WBQ*) ENTRIES * FOR THE SPECIFIED NOP (IF THERE ARE ANY). * * PROC CSCPNQ (NACN, MSGFLAG) * * ENTRY 1. NACN = ACN FOR THE NOP IN QUESTION. * (THIS IS ALSO THE ORDINAL OF THE ACN LIST ENTRY * FOR THIS NOP. THE ACN LIST ENTRY CONTAINS ALL * REQUIRED INFORMATION - NAMELY, THE COUNT OF * *WBQ* ENTRIES.) * 2. THE *WBQ* CONTAINS ZERO OR MORE ENTRIES FOR THE GIVEN * NOP. * * EXIT 1. ALL *WBQ* ENTRIES FOR THIS NOP HAVE BEEN DELETED. * 2. THE COUNT OF *WBQ* ENTRIES IN THE ACN LIST ENTRY FOR * THE GIVEN NOP HAS BEEN CLEARED. * 3. MSGFLAG = TRUE, IF AN *MSG* BLOCK WAS QUEUED. * = FALSE, IF ONLY *BLK* OR NO BLOCKS WERE * QUEUED. # # **** PROC CSCPNQ - XREF LIST. # XREF PROC SSTRTS; # REMOVE TABLE SPACE # # **** # ITEM NACN; # NOP"S ACN # ITEM MSGFLAG B; # RETURN PARAMETER, TRUE=MSG, FALSE=BLK # ITEM I, J; # LOOP INDUCTION VARIABLES AND ORDINALS # # * DELETE THE ENTRIES. IN ORDER TO DELETE AN ENTRY, WE MUST FIRST * LOCATE IT. CLEAR THE WAITING BLOCK COUNT IN THE ACN LIST ENTRY. # MSGFLAG = FALSE; J = 0; FOR I=1 STEP 1 UNTIL ACN$WBCNT[NACN] DO # FIND AND DEL NOP'S *WBQ* NTRYS, ZERO OK # BEGIN FOR J=J STEP WBQ$ESIZE[J] WHILE WBQ$ABHACN[J] NQ NACN DO # FIND NOP"S *WBQ* ENTRY # BEGIN END IF WBQ$ABT[J] EQ APMSG THEN MSGFLAG = TRUE; SSTRTS (P, J, WBQ$ESIZE[J]); # DELETE WAITING BLOCK # END ACN$WBCNT[NACN] = 0; # UPDATE ACN LIST ENTRY # END # CSCPNQ # TERM