The OpenMP Forums are now closed to new posts. Please visit Stack Overflow if you are in need of help: https://stackoverflow.com/questions/tagged/openmp
void omp_set_max_active_levels() runtime routine
page 121. "If the number of parallel levels requested is not a positive integer, the call has no effect."
OMP_MAX_ACTIVE_LEVELS env var
page 144. "The behavior of the program is implementation defined ... if the value is not a positive integer."
It looks like it could make sense for the Specification to be consistent and to declare consistent behavior in case of “non-positive integer” for both the env var and the runtime routine. For example, as “implementation defined”.
The reference close precedent.
Compare with what the Specification says about omp_set_num_threads() and OMP_NUM_THREADS.
page 104. "... or else the behavior of this routine is implementation defined".
page 141. "The behavior of the program is implementation defined ... if the value is not a positive integer."