HOME
| OPENMP API Specification: Version 5.0 November 2018

2.13.1  Parallel Worksharing-Loop Construct

SummaryThe parallel worksharing-loop construct is a shortcut for specifying a parallel construct containing a worksharing-loop construct with one or more associated loops and no other statements.

Syntax

SVG-Viewer needed.

The syntax of the parallel worksharing-loop construct is as follows:  

 
#pragma omp parallel for [clause[ [,] clause] ... ] new-line 
   for-loops  

where clause can be any of the clauses accepted by the parallel or for directives, except the nowait clause, with identical meanings and restrictions.

SVG-Viewer needed.

SVG-Viewer needed.

The syntax of the parallel worksharing-loop construct is as follows:  

 
!$omp parallel do [clause[ [,] clause] ... ] 
   do-loops 
[!$omp end parallel do]  

where clause can be any of the clauses accepted by the parallel or do directives, with identical meanings and restrictions.

If an end parallel do directive is not specified, an end parallel do directive is assumed at the end of the do-loops. nowait may not be specified on an end parallel do directive.

SVG-Viewer needed.

DescriptionThe semantics are identical to explicitly specifying a parallel directive immediately followed by a worksharing-loop directive.

Restrictions

Cross References