Agree!

Charles

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf 
Of John McKown
Sent: Tuesday, September 22, 2015 10:37 AM
To: [email protected]
Subject: Re: Getting the TIOT

On Tue, Sep 22, 2015 at 11:25 AM, Phil Smith <[email protected]> wrote:

> To find the TIOT, a colleague uses GETDSAB, then pulls DSABTIOT out of 
> that. I've always seen:
>          L     R3,540        Get TCB address
>          L     R3,12(,R3)    Get TIOT address
> ...which seems a tad bit mo' shorter :)
>
> Looking at GETDSAB, it's beautifully commented with over 500 lines of 
> preamble, none of which explain what the DSAB is or why one would want 
> to get one (OK, that's a different rant - z/OS doc in general is 
> really short on theology; z/VM doc is MUCH better about this).
>
So the real question: I expect GETDSAB is the documented interface, but is
> the two-line approach common? Aside from theoretical changes, is there 
> any reason not to use it?
>

​Personal opinion. The above code has worked since, at least, OS/MVT. But, as 
mentioned by others, it only works for the TIOT​. GETDSAB is an architected 
API. Which, for me, "seals the deal" about which should be used. My basic 
philosophy, any more, is use a documented, architected API when such will do 
the job. Even if it is overkill for the current need.
Mainly because clever code will likely need to be maintained by those who are 
not so clever. Of course, there is a penalty for doing this. Your code will 
most likely consume more CPU. If this is a DIE exit or something done thousands 
of times a minute, this become the overriding consideration. If this is an 
hourly batch job which runs for 5 minutes, who really cares?

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to