MACRO @V407508 00001000 &NAME COUNT &CTVALUE,&R1,&R2 @V407508 00002000 GBLB &AP @V407508 00003000 LCLC &W1,&W2,&IN @V407508 00004000 &IN SETC '&SYSNDX' @V407508 00005000 AIF (T'&NAME EQ 'O').NOLAB @V407508 00006000 &NAME DS 0H @V407508 00007000 .NOLAB ANOP @V407508 00008000 AIF (T'&CTVALUE EQ 'O').ERR1 @V407508 00009000 &W1 SETC 'R14' @V407508 00010000 &W2 SETC 'R15' @V407508 00011000 AIF (T'&R1 EQ 'O').REG1 @V407508 00012000 &W1 SETC '&R1' @V407508 00013000 AIF ('&W1'(1,1) EQ 'R').REG1 @V407508 00014000 &W1 SETC 'R&W1' @V407508 00015000 .REG1 AIF ('&AP' EQ '0').UP @V407508 00016000 AIF (T'&R2 EQ 'O').REG2 @V407508 00017000 &W2 SETC '&R2' @V407508 00018000 AIF ('&W2'(1,1) EQ 'R').REG2 @V407508 00019000 &W2 SETC 'R&W2' @V407508 00020000 .REG2 AIF ('&W1' EQ '&W2').ERR2 @V407508 00021000 L &W2,&CTVALUE GET ORIGINAL VALUE OF COUNT @V407508 00022000 COU&IN.A DS 0H @V407508 00023000 LA &W1,1 LOAD INCREMENT OF 1 @V407508 00024000 ALR &W1,&W2 ADD TO ORIGINAL COUNT @V407508 00025000 TM APSTAT1,APUOPER IS THE AP OPERATIONAL? @V407508 00026000 BZ COU&IN.B NO, SKIP C&S INSTRUCTION @V407508 00027000 CS &W2,&W1,&CTVALUE TRY TO INCREMENT COUNT @V407508 00028000 BNE COU&IN.A IF NOT SUCCESSFUL, TRY AGAIN @V407508 00029000 B COU&IN.C IF SUCCESSFUL, ALL DONE @V407508 00030000 COU&IN.B ST &W1,&CTVALUE INCREMENT COUNT WITHOUT C&S @V407508 00031000 COU&IN.C DS 0H @V407508 00032000 MEXIT @V407508 00033000 .UP ANOP @V407508 00034000 LA &W1,1 GET INCREMENT OF 1 @V407508 00035000 AL &W1,&CTVALUE ADD TO ORIGINAL COUNT @V407508 00036000 ST &W1,&CTVALUE STORE UPDATED COUNT @V407508 00037000 MEXIT @V407508 00038000 .ERR1 MNOTE 8,'REQUIRED POSITIONAL OPERAND MISSING' @V407508 00039000 MEXIT @V407508 00040000 .ERR2 MNOTE 8,'INVALID REGISTER SPECIFICATION' @V407508 00041000 MEND @V407508 00042000