OpenMP Environment Variables

 

For the latest documentation on Visual Studio 2017 RC, see Visual Studio 2017 RC Documentation.

Provides links to environment variables used in the OpenMP API.

The Visual C++ implementation of the OpenMP standard includes the following environment variables. These environment variables are read at program startup and modifications to their values are ignored at runtime (for example, using _putenv, _wputenv).

Environment variableDescription
OMP_DYNAMICSpecifies whether the OpenMP run time can adjust the number of threads in a parallel region.
OMP_NESTEDSpecifies whether nested parallelism is enabled, unless nested parallelism is enabled or disabled with omp_set_nested.
OMP_NUM_THREADSSets the maximum number of threads in the parallel region, unless overridden by omp_set_num_threads or num_threads.
OMP_SCHEDULEModifies the behavior of the schedule clause when schedule(runtime) is specified in a for or parallel for directive.

Library Reference

Show: