OPEN (SNAPO,(OUTPUT))
SNAP DCB=SNAPO,ID=001,STORAGE=(STARTADR,ENDADDR)
PACK DBLWORD,Y
SNAP DCB=SNAPO,ID=002,STORAGE=(STARTADR,ENDADDR)
CVB R11,DBLWORD
SNAP DCB=SNAPO,ID=003,STORAGE=(STARTADR,ENDADDR)
ZAP Z,W
SNAP DCB=SNAPO,ID=004,STORAGE=(STARTADR,ENDADDR)
AP Z,X
SNAP DCB=SNAPO,ID=005,STORAGE=(STARTADR,ENDADDR)
AP Z,DBLWORD+6(2)
SNAP DCB=SNAPO,ID=006,STORAGE=(STARTADR,ENDADDR)
CLOSE (SNAPO)
* RESTORE REGISTERS AND RETURN WITH RC=0
L R13,4(R13)
LM R14,R12,12(R13)
XR R15,R15
BR R14
LTORG
**************************************************
* STORAGE FOR MAIN *
**************************************************
MAINSAVE DS 18F
STARTADR EQU *
W DC PL2'10'
X DC PL2'-6'
Y DC CL2'15'
Z DC PL2'8'
DBLWORD DC D'0'
ENDADDR EQU *
*
SNAPO DCB DDNAME=SYSOUT,BLKSIZE=1632,DSORG=PS,LRECL=125,MACRF=(W),X
RECFM=VBA
produces results (extracted) of
244 STEP STEP1 TIME 134553 DATE 12235 ID = 001 CPUID =
ENTRY TO SNAP 078D1000 00007E42 ILC 02 INTC 0033
010C006D F1F5008C *
00000000 00000000 00000000 *..
244 STEP STEP1 TIME 134553 DATE 12235 ID = 001
DUMP INDEX
----------
AS PAGE NUMBER
-- -----------
ATED TO TCB AT: 008FF890/.... 00000001
REAS......................... 00000001
MP
244 STEP STEP1 TIME 134553 DATE 12235 ID = 002 CPUID =
ENTRY TO SNAP 078D1000 00007E72 ILC 02 INTC 0033
010C006D F1F5008C *
00000000 0000015F 00000000 *..
244 STEP STEP1 TIME 134553 DATE 12235 ID = 002
DUMP INDEX
----------
AS PAGE NUMBER
-- -----------
ATED TO TCB AT: 008FF890/.... 00000001
REAS......................... 00000001
MP
244 STEP STEP1 TIME 134553 DATE 12235 ID = 003 CPUID =
ENTRY TO SNAP 078D1000 00007EA2 ILC 02 INTC 0033
010C006D F1F5008C *
00000000 0000015F 00000000 *..
244 STEP STEP1 TIME 134553 DATE 12235 ID = 003
DUMP INDEX
----------
AS PAGE NUMBER
-- -----------
ATED TO TCB AT: 008FF890/.... 00000001
REAS......................... 00000001
MP
244 STEP STEP1 TIME 134553 DATE 12235 ID = 004 CPUID =
ENTRY TO SNAP 078D1000 00007ED2 ILC 02 INTC 0033
010C006D F1F5010C *
00000000 0000015F 00000000 *..
244 STEP STEP1 TIME 134553 DATE 12235 ID = 004
DUMP INDEX
----------
AS PAGE NUMBER
-- -----------
ATED TO TCB AT: 008FF890/.... 00000001
REAS......................... 00000001
MP
244 STEP STEP1 TIME 134553 DATE 12235 ID = 005 CPUID =
ENTRY TO SNAP 078D1000 00007F02 ILC 02 INTC 0033
010C006D F1F5004C *
00000000 0000015F 00000000 *..
244 STEP STEP1 TIME 134553 DATE 12235 ID = 005
DUMP INDEX
----------
AS PAGE NUMBER
-- -----------
ATED TO TCB AT: 008FF890/.... 00000001
REAS......................... 00000001
MP
244 STEP STEP1 TIME 134553 DATE 12235 ID = 006 CPUID =
ENTRY TO SNAP 078D1000 00007F32 ILC 02 INTC 0033
010C006D F1F5019C *
00000000 0000015F 00000000 *..
244 STEP STEP1 TIME 134553 DATE 12235 ID = 006
DUMP INDEX
----------
AS PAGE NUMBER
-- -----------
ATED TO TCB AT: 008FF890/.... 00000001
REAS......................... 00000001
which shows you precisely what is in memory each step of the way. Adding PDATA=(REGS) to the SNAP statement would add the registers, but that adds a lot of lines to the display and doesn't really provide much assistance in this particular case. The program output variables start 010C006D and go to the next line in each output (watch for ID = nnn to change).