RE: Base-less macros
Seymour J Metz
Tue 11/23/2021 12:48 PM
> Maybe I missed something?

Actually, I did; the LARL is necessary. Sorry.

> I had started to use:

It would have been correct with an ALR or LA rather than an L.

> they're cleaner than trying to use the select structured macro (IMO).

chacun à son goût


--
Shmuel (Seymour J.) Metz
http://mason.gmu.edu/~smetz3

________________________________________
From: IBM Mainframe Assembler List [ASSEMBLER-LIST@LISTSERV.UGA.EDU] on behalf 
of Mark Hammack [mark.hamm...@gmail.com]
Sent: Tuesday, November 23, 2021 12:36 PM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
Subject: Re: Base-less macros

Thanks everyone!

Seymour, I don't see anywhere that Branch Relative on Condition takes an
"index register".  Maybe I missed something?

Charles, the macro I wrote has bounds checking (one of the reasons I wrote
it was because I found the potential for exactly the problem you mention).

I may have gotten mixed up.  I had started to use:

LARL  14,*+((48+32+16)/8)
L         14,0(15,14)
BR       14
DC   A(RC0ROUTINE)
DC    A(RC4ROUTINE)
DC    A(RC8ROUTINE)

and confused myself.

I'm not real big on branch tables myself but they're cleaner than trying to
use the select structured macro (IMO).  Also, my intent was to hide a lot
of the branch table weaknesses.  From a LOOONG time ago, the original IBM C
compiler implemented branch tables for switch/case.

Steve, I need to investigate BAS.  Thought about BAL but guess I never
"equated" the two.

*Mark Hammack*

Systemware, Inc.
Senior z/OS Developer
mark.hamm...@gmail.com
214-478-0955 (c)

Reply via email to