Why not change your entry code slightly: WHATEVER CSECT ENTRY0 JAS R15,MAIN ENTRY1 JAS R15,MAIN ENTRY2 JAS R15,MAIN ENTRY3 JAS R15,MAIN ENTRY4 JAS R15,MAIN LARL R12,WHATEVER SR R15,R12 subtract r12 from R15 to get relative offset from WHATEVER * R15 = 4 to 20 for entry 0 to 4 AHI R15,-4 R15 = 0 to 16 for entry 0 to 4 SRL R15,2 R15 now has a code 0 to 4 corresponding to the entry point
If you can live with 4 to 16 as your "code", then drop the AHI and your R15 code will be 1 to 5. C- Charles (Chuck) Hardee Senior Systems Engineer/Database Administration EAS Information Technology Thermo Fisher Scientific 300 Industry Drive | Pittsburgh, PA 15275 Phone +1 (724) 517-2633 | Mobile +1 (412) 877-2809 | FAX: +1 (412) 490-9230 chuck.har...@thermofisher.com | www.thermofisher.com WORLDWIDE CONFIDENTIALITY NOTE: Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent of a system responsible for delivering the message to the intended recipient, is prohibited. If you are not the intended recipient, please inform the sender and delete all copies. -----Original Message----- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Steve Smith Sent: Monday, July 03, 2017 4:56 PM To: IBM-MAIN@LISTSERV.UA.EDU Subject: Re: Another elementary Assembler question If invoked with system services (LINK, EXEC, etc.) in AMODE 64, then R15 does not point to anything at all (S0C4-3? if you thought it did). sas On Mon, Jul 3, 2017 at 5:11 PM, Charles Mills <charl...@mcn.org> wrote: > I have a program that has five (IIRC) entry points and sorts them out that > way. > > WHATEVER CSECT > ENTRY0 J MAIN > ENTRY1 J MAIN > ENTRY2 J MAIN > ENTRY3 J MAIN > ENTRY4 J MAIN > > LARL R12,WHATEVER > USING WHATEVER,R12 Optional; irrelevant to this logic > > SR R15,R12 > SRL R15,2 R15 now has a code 0 to 4 corresponding to > the entry point > > Charles > > > -----Original Message----- > From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On > Behalf Of Webster, Chris > Sent: Monday, July 3, 2017 1:33 PM > To: IBM-MAIN@LISTSERV.UA.EDU > Subject: Re: Another elementary Assembler question > > An alternative to looking up the cde. > > Entry Alias1 > Alias1 J Main r15 points here for alias1 Entry Alias2 > Alias2 J Main r15 points here for alias2 Entry MAIN Main DS 0AD r15 points > here for main Larl 12,Main (or data area) set base Using main,12 Larl > 0,alias1 check for alias1 > Cr 15,0 > Je ... > > For amode 64, some cleanup of r15 would be needed. > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN > -- sas ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN