Many of us out here would like to help you, but where is the 0C4 or 0C1? A snip of the dump with the registers and the PSW would help a lot.
Chris Blaicher Senior Software Engineer, Software Services Syncsort Incorporated 50 Tice Boulevard, Woodcliff Lake, NJ 07677 P: 201-930-8260 | M: 512-627-3803 E: cblaic...@syncsort.com www.syncsort.com Check out our Knowledge Base at www.syncsort.com/support Syncsort aims for the best product and service experience. We welcome your feedback. -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Staffan Tylen Sent: Monday, February 13, 2012 11:31 AM To: MVS List Server 1 Subject: Abend S0C4 in an internal sort I can't get my head around this one, I'm 100% sure the answer is starring at me but I just don't see it. I'm writing an assembler program that invokes SORT using LINK. There are E15 and E35 exits to handle records going in and out of the sort, but it keeps abending with S0C4 and sometimes S0C1, depending on whether the exit routines are half or fullword aligned :( To eliminate other possible causes I created the following very simple program where the E15 exit returns RC=16 to tell SORT just to terminate without doing anything. But it also abends in the same way. The PSW seems to point at an unrelated ISPF module in the LPA, but I haven't investigated that further. This is the code: TEST60 CSECT TEST60 AMODE 31 TEST60 RMODE ANY SAVE (14,12) LR 12,15 USING TEST60,12 LA 11,SAVEAREA ST 11,8(,13) ST 13,4(,11) LR 13,11 LA 1,SORTPARM LINK EP=SORT L 13,4(,13) ST 15,16(,13) LM 14,12,12(13) BR 14 DS 0F SAVEAREA DS 18F SORTPARM DC A(SORTSTMT) DC A(E15_EXIT) DC A(E35_EXIT) DC F'-1' SORTSTMT DC AL2(SORTEND-SORT) SORT DC C' SORT FIELDS=(1,1,CH,A)' DC C' RECORD TYPE=F,LENGTH=80' SORTEND EQU * E15_EXIT DS 0F LA 15,16 Terminate SORT BR 14 E35_EXIT DS 0F LA 15,8 BR 14 END TEST60 It can't be more simple than this, like any piece of "Hello World" code. I've tried linkedit as either RENT or NORENT, same result. The sort program produces diagnostic messages on SYSOUT as expected, so it gets called OK. So, who is the first to spot the obvious flaw that I can't see? Thanks for helping out. Staffan ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: INFO IBM-MAIN ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: INFO IBM-MAIN