Performance considerations for sort processing options
REORG PLUS does not require sort work data sets when any of the following conditions exist. In each of these cases, REORG PLUS does not perform a sort.
- You are reorganizing a LOB table space and SHRLEVEL REFERENCE is in effect
- Either of the following conditions exists for a two-phase reorganization, or for a single-phase reorganization with SHRLEVEL REFERENCE or SHRLEVEL CHANGE specified:
- You are performing an index reorganization with ORDER NO specified.
- You are performing one of the following table space reorganizations:
- A single-table table space (simple or segmented) with no indexes defined
- A multitable simple table space with no indexes defined and ORDER NO specified
All other types of reorganizations perform a sort.
To enhance the performance of REORG PLUS and other applications running on your system, you can modify options that control the BMCSORT technology and sort optimization. In addition, the SMAX or MAXSORTS option controls the number of sort processes. The following sections provide information that can help you improve the performance of your sort processing.
Controlling memory usage
REORG PLUS provides several installation and command options to give you control, when necessary, over the amount of memory that BMCSORT uses during a reorganization job.
The SMCORE option contains two parameters: total memory and below-the-line memory. We strongly recommend that you use the values 0K and 0K for the SMCORE option. With these values, you generally obtain the highest sort performance for your REORG PLUS job. Using 0K for total memory and below-the-line memory indicates that REORG PLUS is to determine the appropriate amount of memory to use for each sort based on the following criteria:
- Amount of data to be sorted
- Number of sorts to process, as discussed in Controlling the number of sort processes
- Value that you specify for REGION in either your JCL or system exits
- Amount of memory that is available during optimization
Percentage of available or total 4-KB system pages that you specify with the AVAILPAGEPCT and TOTALPAGEPCT options
- Minimum and maximum amounts of memory per sort that you specify with the MINSORTMEMORY and MAXSORTMEMORY options
- Values that you specify for the multitasking installation options described in Multitasking installation options
Total memory
The first parameter value of the SMCORE option tells REORG PLUS how much total memory, both above and below the 16-MB line, you want BMCSORT to use during a single invocation. We strongly recommend that you specify a value of 0K. However, other valid values are 4096K through 65536K. You can also specify the SMCORE value in megabytes (0M or 4M through 64M).
The region size available for your reorganization job in conjunction with the value that you specify for total memory can constrain the number of sort processes that REORG PLUS starts. Because the region size must include space for buffers and other required structures, the entire region size is not available for sort processing. You can avoid this constraint by using values of 0K and 0K, allowing REORG PLUS to determine the optimal amount of total memory to use.
Additional considerations
The following additional considerations apply when you use the sort optimization options and also specify a value greater than 0 for the SMCORE total memory parameter:
- REORG PLUS uses the SMCORE value that you specify, regardless of other memory factors, including values specified for the MINSORTMEMORY installation or command option and MAXSORTMEMORY installation or command option. That is, if you specify an SMCORE total memory value that is lower than the MINSORTMEMORY value or greater than the MAXSORTMEMORY value, REORG PLUS still uses your specified value.
- If you specify a value greater than 0 for the total memory parameter, REORG PLUS honors your specified total memory value.
Below-the-line memory
The second parameter value of the SMCORE option indicates how much memory BMCSORT should use below the 16-MB line during a single invocation. Unless otherwise noted, BMC recommends that you specify a value of 0K, which allows REORG PLUS to determine the optimal amount of below-the-line memory to use. In addition to 0K, valid values are 256K through 4096K. You can also specify this value in megabytes (either 0M or 1M through 4M). If you specify a value of 0 for the below-the-line memory parameter, REORG PLUS computes below-the-line memory.
When you specify a value of 0 for the below-the-line memory parameter, the amount of memory that BMCSORT uses is controlled by the value of the SORTNUM option as follows:
SORTNUM value | Minimum amount of memory used for all sorts |
|---|---|
32 or less | 256 KB |
33-99 | 384 KB |
100-255 | 1024 KB |
When you specify a value greater than 0 for the below-the-line memory parameter, REORG PLUS honors the other sort optimization options (which apply to total memory only) and also uses your specified SMCORE value.
For example, if you specify SMCORE=(0K,700K) and SORTNUM=32, REORG PLUS responds as follows:
- Uses all of the sort optimization installation and command options to calculate the total memory that is required for sort processing
- Uses 700 KB of memory below the line
Controlling the number of sort processed
REORG PLUS determines the optimal number of sort processes that can execute concurrently, depending on available resources. Under normal circumstances, you should allow REORG PLUS to control the number of sorts processed concurrently.
You can specify the maximum number of concurrent sort processes by using the SMAX installation option. We recommend that you use the default value of 0 for the SMAX installation option.
You can also specify the MAXSORTS option of the REORG command to set the maximum number of concurrent sort processes. For more information, see the description of the MAXSORTS option, which shows MAXSORTS combined with the other sort options.
If the value of the MAXSORTS command option or SMAX installation option is nonzero, REORG PLUS starts at most one task per CPU. You can improve performance by starting more than one task per CPU. To do so, set SMAX=0 (if you specify MAXSORTS in the command, use 0 for the MAXSORTS value), and use the multitasking installation options (TASKMAX, RORGMAX, UNLDMAX, and BILDMAX). For information about using these options, see Multitasking installation options.