>>​File descriptors are mainly what are kept. But the DD statements are all 
>>FREEd. As is user memory. The only DD which can be kept is the STEPLIB and 
>>only if the environment variable STEPLIB exists and is equal to "CURRENT".​ 
>>  
>Is STEPLIB kept or reallocated?  Suppose, e.g. another job is waiting on an 
>ENQ for a DSN in that STEPLIB.  Will that other job intrude?  Suppose the 
>STEPLIB before exec() includes an uncatalogued data set.  Will the exec()ed 
>program get the  same data set? 


The details on processing the STEPLIB environment variable are documented with 
the exec() functions in the C/C++ Runtime Library Reference, and with the 
BPX1ATX, BPX1ATM, and BPX1EXC services in the UNIX  Assembler Callable Services 
Reference.


The text explicitly states that uncataloged data sets are ignored when 
establishing the new steplib concatenation. It also states that data sets are 
ignored when the user does not have access rights, and when it is not load 
library. 


It does not talk about ENQueue behaviour. I did some experiment running a C 
program doing a combination of sleep() and exec() through JCL with some STEPLIB 
data sets. Then a second job was submitted with DISP=OLD on one of the STEPLIB 
data sets from the first job. 


From the behaviour I've seen, I conclude that upon exec():
o The initiator DEQueues the STEPLIB data sets as usual. I.e. ENQueues are kept 
if the data set is used in a JCL DD later in the job, else it is DEQueued.
o The system silently ignores data sets as part of steplib setup when it 
*cannot* ENQueue on the data set. Only data sets where an ENQueue could be 
obtained are part of this substep's steplib concatenation (of course only 
existing cataloged data sets).


In other words, another job might have to wait until the current STEPLIB data 
set is freed (DEQueued) upon exec(). The other job will then gain access and 
might in turn influence what gets allocated as new steplib and what not. The 
behaviour is further influenced by time. 


I have sent an RCF requesting clarification on this. We'll see what they 
answer. I'll post when I get an answer.


--
Peter Hunkeler
 




  
 


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to