12.07.2015 Views

PGI Fortran - Servidor WWW del Cluster Ladon-Hidra

PGI Fortran - Servidor WWW del Cluster Ladon-Hidra

PGI Fortran - Servidor WWW del Cluster Ladon-Hidra

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

• When SCHEDULE (GUIDED, chunk) is specified, the chunk size is reduced in anexponentially decreasing manner with each dispatched piece of the iteration space.Chunk specifies the minimum number of iterations to dispatch each time, except whenthere are less than chunk iterations remaining to be processed, at which point allremaining iterations are assigned. If no chunk is specified, a default chunk size is chosenequal to 1.• When SCHEDULE (RUNTIME) is specified, the decision regarding iteration schedulingis deferred until runtime. The schedule type and chunk size can be chosen at runtime bysetting the OMP_SCHEDULE environment variable. If this environment variable is not set,the resulting schedule is equivalent to SCHEDULE(STATIC).8.7 BARRIERThe OpenMP BARRIER directive uses the following syntax.!$OMP BARRIERThere may be occasions in a parallel region when it is necessary that all threads complete work tothat point before any thread is allowed to continue. The BARRIER directive synchronizes allthreads at such a point in a program. Multiple barrier points are allowed within a parallel region.The BARRIER directive must either be executed by all threads executing the parallel region or bynone of them.8.8 DOACROSSThe C$DOACROSS directive is not part of the OpenMP standard, but is supported forcompatibility with programs parallelized using legacy SGI-style directives.Syntax:Clauses:C$DOACROSS [ Clauses ]< Fortran DO loop to be executed in parallel >[ {PRIVATE | LOCAL} (list) ][ {SHARED | SHARE} (list) ][ MP_SCHEDTYPE={SIMPLE | INTERLEAVE} ][ CHUNK= ][ IF (logical_expression) ]The C$DOACROSS directive has the effect of a combined parallel region and parallel DO loopapplied to the loop immediately following the directive. It is very similar to the OpenMPPARALLEL DO directive, but provides for backward compatibility with codes parallelized forSGI systems prior to the OpenMP standardization effort. The C$DOACROSS directive must not296 Chapter 8

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!