The PROCESSORS directive declares one or more rectilinear processor arrangements, specifying for each its name, its rank, and the extent in each dimension.
The PROCESSORS directive takes the following form:
Rules and Behavior
If no shape (e-spec) is specified, the declared processor arrangement is conceptually scalar. A scalar processor arrangement can be useful as a way of indicating that certain scalar data should be kept together but need not interact strongly with distributed data.
Returning from a subprogram causes all processor arrangements declared local to that subprogram to become undefined.
Every dimension of a processor arrangement must have nonzero extent. (A processor arrangement cannot be empty.)
A processor arrangement cannot have the same name as another entity (for example, a variable, named constant, or internal procedure) in the same scoping unit. Names of processor arrangements obey the same rules for host and use association as other names in Fortran 90.
The PROCESSORS directive can appear only in the specification part of a scoping unit.
You can use the intrinsic functions NUMBER_OF_PROCESSORS and PROCESSORS_SHAPE to inquire about the total number of actual physical processors used to execute the program. This information can be used to calculate appropriate sizes for the declared abstract processor arrangements.
The following are examples of the PROCESSORS directive:
!HPF$ PROCESSORS P(N) !HPF$ PROCESSORS Q(NUMBER_OF_PROCESSORS()), & !HPF$ R(8,NUMBER_OF_PROCESSORS()/8) !HPF$ PROCESSORS SCALARPROC
An optional double colon (::) can be inserted following the directive, and the shape can also be specified by using the DIMENSION attribute. For example:
!HPF$ PROCESSORS :: RUBIK(3,3,3) !HPF$ PROCESSORS, DIMENSION(3,3,3) :: RUBIK
For More Information: