Program residence and storage considerations
Compiler option
The following compiler options can affect where the program resides (above/below the 16 MB line), which in turn can affect the location of WORKING-STORAGE section, and I/O file buffers and record areas.
RENT or NORENT
Using the RENT compiler option causes the compiler to generate some additional code to ensure that the program is reentrant. Reentrant programs can be placed in shared storage like the Link Pack Area (LPA) or the Extended Link Pack Area (ELPA). Also, the RENT option will allow the program to run above the 16 MB line. Producing reentrant code may increase the execution time path length slightly.
Performance considerations using RENT: On the average, RENT was equivalent to NORENT.
For details, see RENT in the Enterprise COBOL for z/OS® Programming Guide.
RMODE - AUTO, 24, or ANY
The RMODE compiler option determines the RMODE setting for the COBOL program. When using RMODE(AUTO), the RMODE setting depends on the use of RENT or NORENT. For RENT, the program will have RMODE ANY. For NORENT, the program will have RMODE 24. When using RMODE(24), the program will always have RMODE 24. When using RMODE(ANY), the program will always have RMODE ANY.
While it is not expected to impact the performance of the application, it can affect where the program and its WORKING-STORAGE are located.
For details, see RMODE in the Enterprise COBOL for z/OS Programming Guide.
Location of Storage
WORKING-STORAGE
COBOL WORKING-STORAGE is allocated from the Language Environment® heap storage when the program is compiled with the RENT option.
LOCAL-STORAGE
COBOL LOCAL-STORAGE is always allocated from the Language Environment stack storage. It is affected by the LE STACK runtime option.
EXTERNAL variables
External variables in an Enterprise COBOL program are always allocated from the Language Environment heap storage.
QSAM buffers
- The programs are compiled with VS COBOL II Release 3.0 or higher, COBOL/370 Release 1.0 or higher, IBM® COBOL for MVS & VM Release 2.0 or higher, IBM COBOL for OS/390® & VM, or IBM Enterprise COBOL
- The programs are compiled with RENT and DATA(31) or compiled with NORENT and RMODE(ANY)
- The program is executing in AMODE 31
- The ALL31(ON) and HEAP(,,ANYWHERE) runtime options are used (for EXTERNAL files)
- The file is not allocated to a TSO terminal
- The file is not spanned external, spanned with a SAME RECORD clause, or spanned opened as I-O and updated with REWRITE
For details, see Allocation of buffers for QSAM files in the Enterprise COBOL for z/OS Programming Guide.
VSAM buffers
VSAM buffers can be allocated above the 16 MB line if the programs are compiled with VS COBOL II Release 3.0 or higher, COBOL/370 Release 1.0 or higher, IBM COBOL for MVS & VM Release 2.0 or higher, IBM COBOL for OS/390 & VM, or IBM Enterprise COBOL.