conditional macro assembler as in: .EXTRM ANOP TERMINAL EXCLUDES DEFINITION 00075800 .* 00075900 &A1 SETA 1 00076000 &C1 SETC '&EXCNT' 00076100 &@SYS SETC 'EXCL&SYSNDX' 00076200 &@SYS DC H'&C1' EXCLUDES COUNT 00076336 .* 00076400 .EXLOOP AIF (&FLHEX).@EXHEX 00076500 &A2 SETA &@EXCLUD(&A1) CONVERT EXCLUDES TO HEXADECIMAL 00076600 &A3 SETA &A2/16 00076700 <-- &C1 SETC '&HEXVAL(&A3+1)' 00076800 &A3 SETA &A2-(&A3*16) 00076900 <-- &C2 SETC '&HEXVAL(&A3+1)' 00077000 &@EXCLUD(&A1) SETC '&C1&C2' 00077100 .@EXHEX DC XL1'&@EXCLUD(&A1)' EXCLUDED 00077200 &A1 SETA &A1+1 00077300 AIF (&A1 LE &EXCNT).EXLOOP 00077400 &@SYS SETC 'EXMK&SYSNDX' 00077500 &@SYS DC XL2'FFFF' END OF EXCLUDES MARKER 00077600 .* 00077700 MNOTE *,' COUNT OF TERMINALS EXCLUDED = &EXCNT' 00077800 &@NZ SETC 'EXTRMOK' 00077900 AGO .EXCNTL END OF TERMINAL EXCLUDES 00078000 .* 00078100 <etc.> Cheers.
On 29/04/2020 03:05, Paul Gilmartin wrote: > On Wed, 29 Apr 2020 02:57:23 +0100, CM Poncelet wrote: > >> ... but that's the only way to do it in conditional macro assembler; so >> what me worry about 3GL's? :) >> > What hardware? Doesn't Divide leave the quotient in one register and the > remainder in an adjacent one? > >> On 28/04/2020 10:46, David Crayford wrote: >>> No worries. FWIW, I think using the // modulo operator would make >>> your code less verbose and complex ;) > -- gil > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to [email protected] with the message: INFO IBM-MAIN > . > ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
