> There is no expectation. There is no concept of the provider "formatting it".

Conventional behavior is for programs to store a back pointer after acquiring a 
new save area, and to store an EBCDIC identifier if appropriate. Is that not 
formatting.

However, I think I see the issue. The called program could store a forward 
pointer at offset 8 and 32-bit registers at offset 12, or could store grande 
registers, with no way to determine which. Is that the issue?.


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

________________________________________
From: IBM Mainframe Assembler List [ASSEMBLER-LIST@LISTSERV.UGA.EDU] on behalf 
of Peter Relson [rel...@us.ibm.com]
Sent: Thursday, January 27, 2022 8:55 AM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
Subject: Re: Saving Caller's 64-bit Registers

Shmuel wrote
>For running forward, it's a bit stickier. Is a program providing a
>144 byte save area expected to format it as FxSA?

As I wrote previously, you cannot in general "run forward". You could if
you know exactly what the target programs are doing (which is unlikely
unless you own them). There is no expectation. There is no concept of the
provider "formatting it". The provider "provides it". The target "uses
it".

It is not in general knowable how the target chose to "use it". The target
could be a routine that expects 72 bytes and uses the first 72 bytes only
(including putting the next address at +8). It could be a routine that
expects 144 bytes in which case it would likely use it according to the
conventions (incuding putting the next address at +x'88')..

Shmuel wrote
<snip>
> A program that saves its caller's registers in standard 72-byte format
> is expected to set offset 4 of the save area that it obtains to the
address
> of the previous save area, regardless of the size of save area that it
provides.

That's not what the manual says. A program that saves the callers
registers in a 72-byte save area and alters ARs or the top halve of GRs is
expected to save them in  a new F5SA or F8SA
</snip>

There is no conflict. The manual section referred to is not what Tom was
referring to. A program that "saves its caller's registers in standard
72-byte format" is not one that (also) saves ARs and/or high halves. That
would be a program that "saves its caller's low halves in standard 72-byte
format and also saves ARs and/or high halves".
And, yes, such a program would (if following the conventions) be using
F5SA/F8SA.

The main important thing, as has been mentioned so many times, is that the
provider of the save area provides space. The provider does not dictate
how that space is to be used. The conventions are such that the uses do
not conflict with respect to being able to locate the previous pointer. A
general routine to format save areas does so. It looks at the value at +4
to decide if that is the previous pointer or if the previous pointer is at
+x'88'.

Peter Relson
z/OS Core Technology Design

Reply via email to