The assembler and binder don't control how you use Q-cons, but it's clear that 
the intended use case is one large storage allocation for a bunch of elements 
that are not all defined in the same source module. The Binder assigns offsets 
and calculates CXD. As a practical matter, the compiler has to pick a size for 
the offsewts and stick to it so that you can link separately compiled modules.

Yes, the early PL/I compilers used signed halfwords for array extents. Bit and 
character strings also had halword lengths.


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

________________________________________
From: IBM Mainframe Assembler List [ASSEMBLER-LIST@LISTSERV.UGA.EDU] on behalf 
of Paul Gilmartin [00000014e0e4a59b-dmarc-requ...@listserv.uga.edu]
Sent: Sunday, July 5, 2020 11:15 AM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
Subject: Re: z390 RLD Entries ... Bug or Feature?

On 2020-07-04, at 23:08:31, Keven wrote:
>
>       2-byte RLD entries are correctly handed by the link-editor/binder and 
> as far as I know they aren’t deprecated.  Why would their use by Pl/I (to use 
> your example) perturb you?
>
My understanding is that Q-constants are offsets into an
obtained storage area.  PL/I places pointers to global
objects in such an area.  SAS/C chose to place the objects
themselves in that area.  CMS Loader supported only 2-byte
Q-constants, severely limiting the total size of SAS/C
global objects.

Didn't PL/I also (previously?) limit subscripts to 16 bits?
Storage was costly.

> On Sat, Jul 4, 2020 at 7:57 PM -0500, "Seymour J Metz" wrote:
>
> The default length of a Q-type constant is 4, although early PL/I compilers 
> used QL2. I don't know whether Enterprise PL/I still uses QL2; I hope not.
>
It's not perturbing if the compiler allows the programmer
the option of 4.  Nowadays, 8 might be desirable.

-- gil

Reply via email to