This information assumes that your program's reference pattern
meets the basic requirement of consistent direction.
Figure 1 identifies tw o reference patterns that
characterize most of the reference patterns that REFPAT applies to.
The marks on the line indicate referenced elements.
Figure 1. Two Typical Reference Patterns
How you define the reference pattern depends on whether your program's
reference pattern is like Pattern #1 or Pattern #2.
- With Pattern #1 where no uniform gap exists, the program
uses every element, every other element, or at least most elements
on each page of array data. No definable gap exists. Do not use REFPAT
if the reference pattern is irregular and includes skipping over many
areas larger than a page.
- The UNITSIZE parameter alone identifies the reference pattern.
(Either omit the GAP parameter or take the default, GAP=0.) UNITSIZE
indicates the number of bytes you want the system to use as a reference
unit. Look at logical groupings of bytes, such as one row, a number
of rows, or one element, if the elements are large in size. Or, you
might choose to divide up the total area, bringing in all the data
on a certain number of page faults.
- The UNITS parameter tells the system how many reference units
to try to bring in on a page fault. For a reference pattern that begins
on a page boundary and has no gap, the total number of bytes the system
tries to bring into central storage at a time is the value on UNITSIZE
times the number on UNITS, rounded up to the nearest multiple of 4096.
See Choosing the number of bytes on a page fault for more information on how to choose
the total number of bytes.
- With Pattern #2 where a uniform gap exists, you tell the
system the sizes of reference units and gaps.
- UNITSIZE and GAP parameters identify the reference pattern. Pattern
#2 in Figure 1 includes a reference unit of
20 bytes and a gap of 5000 bytes. Because the gap is greater than
4095, some pages of the array might not come into central storage.
- The UNITS parameter tells the system how many reference units
to try to bring into central storage at a time. What pages does the system bring in when a gap exists? can
help you understand how many bytes come into central storage at one
time.
Although the system brings in pages 4096 bytes at a time, you do
not have to specify GAP, UNITS, and UNITSIZE values in increments
of 4096.