A Sample Program
The following program illustrates the use of the ABNEXIT macro.
TABNEX1 CSECT
STM R14,R12,12(R13)
USING TABNEX1,R12
ST R13,SAVE+4
LA R13,SAVE
XR R3,R3
ABNEXIT SET,EXIT=EXITSUB,UWORD=WORD,ERROR=ERROR1
XR R2,R2
DR R2,R3 IT WILL CAUSE A PROGRAM CHECK DIVIDING BY ZERO.
XR R2,R2
WRTERM 'END OF MAIN ROUTINE'
OUT L R13,SAVE+4
LM R14,R12,12(R13)
SLR R15,R15
BR R14
ERROR1 EQU *
WRTERM ' AN ERROR OCCURED WHEN EXECUTING THE MACRO'
B OUT
SAVE DS 18F
WORD DS F
******************EXIT ROUTINE*************************************
DROP R12
EXITSUB EQU *
LR R11,R15
USING EXITSUB,R11
LR R4,R1
USING CMSSDWA,R4
USING NUCON,0
ABNEXIT RESET,MF=(L,LIST,SIZ)
ABNEXIT MF=(E,LIST)
APPLMSG TEXT='EXIT ROUTINE ENTERED',APPLID=CMS
OUT2 L R12,SDWREGS+8*6
LPSW SDWPSW
LIST ABNEXIT MF=L
PRINT NOGEN
DMSSDWA
NUCON
REGEQU
END