Hmm, didn't think of using CRTE etc, since I was fixated on CLFITxx instructions. The immediate value is a halfword, so you can code a lot more variations of the CLFIT instruction to uniquely identify which specific instance produced the S0C7.
Robert Ngan HCL P.S. I always seem to code the CLFIT instruction wrongly, since it is the only variation of the COMPARE AND BRANCH/JUMP/TRAP that requires the F, and I keep forgetting the F (although I do understand why the F was added for it). -----Original Message----- From: IBM Mainframe Assembler List <[email protected]> On Behalf Of Jonathan Scott Sent: Monday, August 6, 2018 12:20 To: [email protected] Subject: Re: EX Robert Ngan writes: > Not sure why no one has mentioned the COMPARE AND TRAP type > instructions, in > most(?) cases they'll do the test and force the abend when required. If you have to write product code that still works for CMS users in ESA mode, then COMPARE AND TRAP is not an option. It needs z10 or above, which I think is part of the architectural level set required by z/OS 2.2 so if you are on that level or above it is safe to use. > My only gripe is there's no extended mnemonic for an unconditional > TRAP when there's no appropriate "compare" (e.g. I need to do a TM). I've never used it myself, but I think the simplest way to code an unconditional trap is to use CRTE 0,0 or similar, using two references to the same register which are certain to compare equal. Jonathan Scott, HLASM IBM Hursley, UK DXC Technology Company - Headquarters: 1775 Tysons Boulevard, Tysons, Virginia 22102, USA. DXC Technology Company -- This message is transmitted to you by or on behalf of DXC Technology Company or one of its affiliates. It is intended exclusively for the addressee. The substance of this message, along with any attachments, may contain proprietary, confidential or privileged information or information that is otherwise legally exempt from disclosure. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient of this message, you are not authorized to read, print, retain, copy or disseminate any part of this message. If you have received this message in error, please destroy and delete all copies and notify the sender by return e-mail. Regardless of content, this e-mail shall not operate to bind DXC Technology Company or any of its affiliates to any order or other contract unless pursuant to explicit written agreement or government initiative expressly permitting the use of e-mail for such purpose.
