4.10 OMP_NESTED – Nested parallel regions

ICV: max-active-levels-var
Scope: data environment
Description:

Enable or disable nested parallel regions, i.e., whether team members are allowed to create new teams. The value of this environment variable shall be TRUE or FALSE. If set to TRUE, the number of maximum active nested regions supported is by default set to the maximum supported, otherwise it is set to one. If OMP_MAX_ACTIVE_LEVELS is defined, its setting overrides this setting. If both are undefined, nested parallel regions are enabled if OMP_NUM_THREADS or OMP_PROC_BINDS are defined to a list with more than one item, otherwise they are disabled by default.

Note that the OMP_NESTED environment variable was deprecated in the OpenMP specification 5.2 in favor of OMP_MAX_ACTIVE_LEVELS.

See also:

omp_set_max_active_levels – Limits the number of active parallel regions, omp_set_nested – Enable/disable nested parallel regions, OMP_MAX_ACTIVE_LEVELS – Set the maximum number of nested parallel regions

Reference:

OpenMP specification v4.5, Section 4.6