Compaq Fortran supplies parallel directives that you can use for compatibility with older programs that were written for parallel execution.
This section describes the following parallel directives:
Synchronizes all the threads in a team. This directive is the same as the OpenMP Fortran API BARRIER directive.
Sets a default chunksize to adjust the number of iterations assigned to a thread.
Copies the values of listed data objects from the master thread to PRIVATE data objects of the same name in slave threads.
Restricts access to a block of code to only one thread at a time.
Specifies the availability of named common blocks.
Sets a default run-time scheduling type.
Defines a parallel region. This directive is the same as the OpenMP Fortran API PARALLEL directive with the following exceptions:
Defines a parallel region that contains a single DO directive. This directive is the same as the OpenMP Fortran API PARALLEL DO directive except that the keyword DOACROSS is permitted as an alternative spelling for PARALLEL DO.
Defines a parallel region that contains SECTIONS directives. This directive is the same as the OpenMP Fortran API PARALLEL SECTIONS directive.
Specifies that the iterations of the immediately following DO loop must be executed in parallel.
Terminates the current parallel DO loop.
Specifies a block of code to be divided among threads in a team (a worksharing area). This directive is the same as the OpenMP Fortran API SECTIONS directive with the following exceptions:
Specifies a block of code to be executed by only one thread in a team. This directive is the same as the OpenMP Fortran API SINGLE directive except that LOCAL is permitted as an alternative spelling for the PRIVATE clause.
Makes named common blocks private to a thread but global within the thread. This directive is the same as the OpenMP Fortran API THREADPRIVATE directive except that slashes (/ /) do not have to be used to delimit named common blocks.
The Compaq Fortran parallel directives can be grouped into the categories shown in the following table.
Category | Description |
---|---|
Parallel region | Defines a parallel region: PARALLEL |
Work-sharing | Divide the execution of the enclosed block of code among the members of the team that encounter it: PDO, PSECTIONS, and SINGLE PROCESS |
Combined parallel work-sharing | Shortcut for denoting a parallel region that contains only one work-sharing construct: PARALLEL DO and PARALLEL SECTIONS |
Synchronization | Provide various aspects of synchronization; for example, access to a block of code, or execution order of statements within a block of code: BARRIER and CRITICAL SECTION |
Data Environment | Control the data environment during the execution of parallel constructs: COPYIN, INSTANCE, and TASKCOMMON |
Execution Defaults | Specify a default chunk or schedule type: CHUNK and MP_SCHEDTYPE |
For details on how to use these directives, see your user manual.
See Also: Parallel Directives for Tru64 UNIX Systems, OpenMP Fortran API Compiler Directives (TU*X only)