Hash :
3f61a6d1
Author :
Date :
2017-02-20T20:26:35
nproc: support nested OMP_NUM_THREADS, and OMP_THREAD_LIMIT * lib/nproc.c (parse_omp_threads): A new function refactored from num_processors() to support parsing both of the above environment variables. (num_processors): Prefer using omp_get_num_threads() with [_OPENMP] to accurately reflect the current OpenMP nesting level. Also support the OMP_THREAD_LIMIT environment variable to limit the max value determined from OMP_NUM_THREADS. * modules/nproc: Depend on minmax header. Suggested by Oliver Heimlich.
Description:
Detect the number of processors
Files:
lib/nproc.h
lib/nproc.c
m4/nproc.m4
Depends-on:
c-ctype
extensions
minmax
unistd
configure.ac:
gl_NPROC
Makefile.am:
lib_SOURCES += nproc.c
Include:
"nproc.h"
License:
LGPLv2+
Maintainer:
Glen Lenker and Paul Eggert