FastSort Manual

FastSort Manual429834-003
6-1
6 Sorting in Parallel
If the total input file size is larger than one megabyte, a parallel sort run can provide
better performance in elapsed execution time than a serial sort run. A parallel sort
operation improves performance because it:
Distributes the workload to multiple processors
Uses scratch files on multiple disks
For a parallel sort run, you set up a distributor-collector process and from 2 to 8
subsort processes.
The distributor-collector and subsort processes are SORTPROG processes. You can
use either FastSort commands or system procedures to set up the distributor-collector
and subsort processes. You run each subsort process in a different processor and
assign each processor a different disk for scratch files.
The distributor-collector process reads input files and distributes the records among
the subsort processes. Each subsort process sorts its portion of the records. The
distributor-collector process then collects the sorted records, merges them, and
produces the output file.
Figure 6-1 on page 6-2 shows how multiple SORTPROG processes work together in a
parallel sort run.
Note. Although you can specify a maximum of 16 subsort processes, HP recommends you
specify no more than 8 processes. More than 8 subsort processes can cause a parallel sort
run to fail with FastSort error 22 (THE MEMORY SPACE FOR SORTING IS INSUFFICIENT).