Auto-parallelization Overview

The Intel® Fortran Compiler with the auto-parallelization feature and a high-level symmetric multirpocessing (SMP) programming model enable you with an easy way to exploit the parallelism on SMP systems.

Automatic parallelization relieves the user from having to deal with the low-level details of iteration partitioning, data sharing, thread scheduling and synchronizations. It also provides the benefit of the performance available from multiprocessor systems.

Enabling Auto-parallelizer

To enable auto-parallelizer, use the -parallel option. The -parallel option detects parallel loops capable of being executed safely in parallel and automatically generates multithreaded code for these loops.  An example of the command using auto-parallelization is as follows:

IA-32 compilations:

prompt>ifc -c -parallel -par_threshold0 myprog.f

Itanium-based compilations:

prompt>efc -c -parallel -par_threshold0 myprog.f

Guidelines for Effective Auto-parallelization Usage

Enhance the power and effectiveness of the auto-parallelizer by following these coding guidelines:

Analyzing Compiler for Auto-parallelization

Currently, compiler is analyzed only on loop nests, but potentially on independent regions of code (task parallelism). A loop is parallelizable if:

To prepare auto-parallelization, the compiler performs the following transformations:

- work/overhead threshold analysis

- runtime dependency testing

Auto-parallelization Environment Variables

Option

Description

Default

OMP_NUM_THREADS

Controls the number of threads used.

Number of processors currently installed in the system

OMP_SCHEDULE

Specifies the type of runtime scheduling.

static