There are several different issues here. First, using foo EQU * instead of foo DS 0H will lead to alignment errors in programs mixing instructions and data, which is a very bad practice. Mixing LOCTR separated instructions and data, however, is a perfectly reasonable practice.
Second, with any decent editor it is simple to insert and instruction after the label on another instruction. Third, if yo;re not mixing instructions and data then the difference between foo EQU * and foo DS 0H is purely stylistic. Fourth, stand alone labels will not create appropriate TEST and ADATA output. There might be a similar problem with macros that use the type of a parameter. -- Shmuel (Seymour J.) Metz http://mason.gmu.edu/~smetz3 ________________________________________ From: IBM Mainframe Assembler List [[email protected]] on behalf of David Woolbright [[email protected]] Sent: Tuesday, June 2, 2020 12:58 PM To: [email protected] Subject: Re: z/OS HLASM: EQU for statement labels I’’m just a humble academic so I hesitate to weigh in. I trained assembler programmers for one large credit card processing company for many years and their standard was to use EQU * as the target of all branches, mainly so new lines could be added easily. I’ve never had an odd address created accidentally using this technique, but it’s also the case that the assembler will warn you in cases where you do have an unfavorable address. I’m in the process of revising many years of teaching material into book format, so your opinions on this matter to me. Using EQU for targets would seem to be a stylistic point on which reasonable people could disagree, but perhaps I’m wrong. > On Jun 2, 2020, at 11:49 AM, Seymour J Metz <[email protected]> wrote: > >> Is this useful? > > Only if you're a sadist. > > > -- > Shmuel (Seymour J.) Metz > http://mason.gmu.edu/~smetz3 > > ________________________________________ > From: IBM Mainframe Assembler List [[email protected]] on > behalf of Paul Gilmartin [[email protected]] > Sent: Tuesday, June 2, 2020 11:40 AM > To: [email protected] > Subject: Re: z/OS HLASM: EQU for statement labels > > On 2020-06-02, at 09:33:48, Charles Mills wrote: >> >> I don't claim any benefit to the technique, it's just my habit. Actually I >> think the cleanest is a DS 0H followed by label EQU *. That clearly shows >> what is going on: re-establishing halfword alignment followed by mapping a >> label to an address. >> > I found it ironic that: > LABEL CNOP ... > assigns the address of the beginning of the padding rather > than the end to LABEL. Is this useful? > > Fortunately, > LABEL DS 0H > does the opposite so your 2-instruction construct is otiose. > > -- gil
