On 6 December 2016 at 10:39, Tom Marchant < [email protected]> wrote:
> On Tue, 6 Dec 2016 09:20:33 -0500, Steve Smith wrote: > > >Metal C linkage requires your own forward chain to be preset to the NAB. > I > >think LE C just uses the NAB. Regardless, that shouldn't cause a problem > >either. > > I never heard of such a thing, so I looked it up. > > It is a rather bizarre requirement that seems to me to contradict the > standard linkage conventions that it claims to follow. > > It means that a program must know not only its own storage > requirements, but the storage requirements of every program that it > calls, and every program that they call, etc. > > There is no mechanism to verify that the allocated storage hasn't been > exceeded, or to ensure that the storage that is obtained is adequate. > Well, there is... The traditional approach to this is to use DXD and CXD to have the Binder add up all the requirements at link time. This scheme is sometimes known as "Pseudo registers", and is (was?) used by PL/I. It works well; the only real downside is that it doesn't account for recursive calls, whether direct or indirect. Tony H. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
