OSAM buffer pool compatibility definition
The OSAM buffer pool consists of one or more subpools that are defined using IOBF parameter statements. These statements are required in a DB/DC environment. Default member DFSVSM00 is used if the VSPEC parameter is not coded, but these statements are optional in a batch environment.
Omitting IOBF statements in a batch environment causes the OSAM subpools to be generated based on the following factors:
- The DMBs loaded for execution
- The values specified by the BUF= parameter on the EXEC statement
The BUF= parameter specifies the size of the OSAM buffer pool that is to be used in the subpool compatibility definition calculations. The size specified by the BUF= parameter does not necessarily define the actual size of the buffer pool. The specified size influences the eventual buffer pool size.
The buffer pool is generated as follows:
- IMS inspects each DMB loaded for execution for an OSAM DCB. The buffer length from the DCB is rounded up to the next appropriate subpool size (.5 KB, 1 KB, 2 KB, and so on) and is used to create a potential subpool. DCBs with similar length requirements increment the occurrence count for that subpool.
- The potential number of buffers for each potential subpool is derived from the ratio of actual to least occurrences, multiplied by 4. The minimum number of buffers allowed per subpool is four.
- IMS allocates the actual number of subpool and buffers according to the previous ratio allocation using the buffer pool size specified by the BUF= parameter. The objective is to allocate at least four buffers per subpool without exceeding the specified size. The process begins with the subpool with the largest buffer size and continues to the subpool with the smallest. Depending on the specified buffer pool size, it might not be possible to generate all required subpools. IMS allocates only those subpools (largest to smallest), with a minimum of four buffers each, that fit in the specified size. A minimum of one subpool with a minimum of four buffers is allocated regardless of the buffer pool size defined. This subpool has a buffer size capable of handling the largest buffer size requirement.
Example: The BUF= parameter is specified as 10 KB. A scan of the loaded DMBs and the block size required by the OSAM DCBs indicates two subpools are required: one with 1 KB buffers, and one with 4 KB buffers. If each subpool has the minimum number of buffers, the total storage for the buffer pool is 20 KB. The size specified (by BUF=) is 10 000 bytes. To support all requests, the subpool having 4 KB buffers must be allocated. The subpool with 1 KB buffers is not allocated. The buffer pool is allocated having one subpool with four 4 KB buffers. The size is 16 KB (plus control areas), even though 10 000 bytes are specified.