Previous topic |
Next topic |
Contents |
Contact z/OS |
Library |
PDF
Creating and using SCOPE=COMMON data spaces z/OS MVS Programming: Extended Addressability Guide SA23-1394-00 |
|
The SCOPE=COMMON data space provides your programs with virtual
storage that is addressable from all address spaces and all programs.
In many ways, it is the same as the common service area (CSA) of
an address space. You might use a SCOPE=COMMON data space instead
of CSA because:
To create this space, use the SCOPE=COMMON parameter on DSPSERV CREATE. You can use any of the parameters on that macro to establish the characteristics of that space. To gain addressability to the space, issue the ALESERV ADD macro with the AL=PASN parameter. ALESERV ADD then adds an entry for the data space to the caller's PASN-AL and returns the ALET for that entry. Additionally, ALESERV ADD adds the same entry to every PASN-AL in the system. As new address spaces come into the system, their PASN-ALs have this entry on them. All programs use the same ALET to access the data space. In other words, with the entry on all PASN-ALs, programs in other address spaces do not have to issue the ALESERV ADD macro. However, the creating program must pass the ALET for the data space to the other programs. The use of the virtual storage in the SCOPE=COMMON data space is similar to the use of the CSA. A program wanting to share CSA storage with another program has to pass the address of that area to the other program; the creator of the SCOPE=COMMON data space has to pass the ALET value to the other program. (It might also have to tell the other program the origin of the data space.) Figure 1 shows an example of a SCOPE=COMMON data space named COMDS that PROG1 created. PROG1 uses ALESERV ADD to add an entry to its PASN-AL. Because COMDS is SCOPE=COMMON,that same entry appears on all PASN-ALs in the system, plus all PASN-ALs that will exist from the time the entry for the SCOPE=COMMON data space is added to the access list until the data space terminates. PROG1 has the ALET for the entry. To give access to COMDS to programs in the other address spaces, PROG1 passes the ALET to the other programs. Figure 1. Example of Using a SCOPE=COMMON Data Space
Programming Considerations: When
you use SCOPE=COMMON data spaces, keep in mind the following advice:
Your installation can use the IEASYSxx member of SYS1.PARMLIB to set limits on the total number of SCOPE=COMMON data spaces available to programs. For information about how to set up this member, see z/OS MVS Initialization and Tuning Reference. |
Copyright IBM Corporation 1990, 2014
|