provide better informative messages when OMP_NUM_THREADS is not set or code was compiled without OpenMP support

This commit is contained in:
Axel Kohlmeyer
2016-07-28 08:03:42 -04:00
parent 6a953aec85
commit 3080bb5341
2 changed files with 7 additions and 1 deletions

View File

@ -87,7 +87,8 @@ Comm::Comm(LAMMPS *lmp) : Pointers(lmp)
} else if (getenv("OMP_NUM_THREADS") == NULL) {
nthreads = 1;
if (me == 0)
error->warning(FLERR,"OMP_NUM_THREADS environment is not set.");
error->warning(FLERR,"OMP_NUM_THREADS environment is not set. "
"Defaulting to 1 thread.");
} else {
nthreads = omp_get_max_threads();
}