The REGION parameter in JCL specifies the amount of main storage (memory) to be allocated to a job or job step. It limits the amount of virtual storage available to programs executing within a job step. REGION can be specified at both the JOB level (affecting all steps) and the EXEC level (for individual steps).
On JOB statement:
1//jobname JOB (accounting-information),programmer-name,REGION=value
On EXEC statement:
1//stepname EXEC PGM=program-name,REGION=value
The REGION parameter can be specified in several formats:
1//PAYROLL JOB (ACCT123),'JOHN SMITH',REGION=4M
Allocates 4 megabytes of memory for all steps in the job
1//STEP1 EXEC PGM=IEBGENER,REGION=8M
Allocates 8 megabytes of memory for this specific step
1//BIGSTEP EXEC PGM=SORT,REGION=0M
Requests maximum available region size for this step
1234//PAYROLL JOB (ACCT456),'JANE DOE',REGION=2M //STEP1 EXEC PGM=PROG1 //STEP2 EXEC PGM=PROG2,REGION=6M //STEP3 EXEC PGM=PROG3
STEP1 and STEP3 use the JOB-level REGION of 2M, while STEP2 overrides with 6M
The REGION parameter controls two types of storage allocation:
Level | Effect | Override |
---|---|---|
JOB statement REGION | Applies to all steps in the job | Can be overridden at the EXEC level |
EXEC statement REGION | Applies only to the specific step | Takes precedence over JOB level REGION |
Size | Typical Use |
---|---|
512K - 2M | Small utility programs (IEFBR14, IDCAMS for simple operations) |
4M - 8M | Medium-sized batch programs, compilers |
16M - 32M | Large batch programs, database utilities |
64M - 128M | Very large applications, sort programs with large datasets |
0M (maximum) | Memory-intensive applications, unpredictable memory needs |
In modern z/OS environments, two parameters control memory allocation: