Hi all,
Is there and equivalent to “OMP_DISPLAY_ENV” for the pgi compilers?
OMP_DISPLAY_ENV=true is not working for me.
Thanks,
Edgar
Hi all,
Is there and equivalent to “OMP_DISPLAY_ENV” for the pgi compilers?
OMP_DISPLAY_ENV=true is not working for me.
Thanks,
Edgar
That is an openmp 4.5 environment variable, and is currently only
supported on LLVM compilers.
Add
-Mllvm
to your compilation, and the environment variable should work.
% setenv OMP_NUM_THREADS 4
% setenv OMP_DISPLAY_ENV .TRUE.
% pgfortran -mp -o m2 m2.f
% m2
c=
30201.00 302000.0
30201.00 302000.0
d=
30000.00 302010.0
30000.00 302010.0
% pgfortran -mp -o m2 m2.f -Mllvm
% m2
OPENMP DISPLAY ENVIRONMENT BEGIN
_OPENMP=‘201611’
[host] OMP_CANCELLATION=‘FALSE’
[host] OMP_DEFAULT_DEVICE=‘0’
[host] OMP_DISPLAY_ENV=‘TRUE’
[host] OMP_DYNAMIC=‘FALSE’
[host] OMP_MAX_ACTIVE_LEVELS=‘2147483647’
[host] OMP_MAX_TASK_PRIORITY=‘0’
[host] OMP_NESTED=‘FALSE’
[host] OMP_NUM_THREADS=‘4’
[host] OMP_PLACES: value is not defined
[host] OMP_PROC_BIND=‘false’
[host] OMP_SCHEDULE=‘static’
[host] OMP_STACKSIZE=‘4M’
[host] OMP_THREAD_LIMIT=‘2147483647’
[host] OMP_WAIT_POLICY=‘PASSIVE’
OPENMP DISPLAY ENVIRONMENT END
c=
30201.00 302000.0
30201.00 302000.0
d=
30201.00 302010.0
30201.00 302010.0
dave
Thanks. That worked for an “pure” OpenMP program.
However, I am getting a segmentation fault if I try to use that parameter (-Mllvm) in a Hybrid (MPI+OpenMP) program.
I am using the MPI implementation that comes with PGI 18.3.
Thanks again for answering.
I think I got it.
I had to change the path to point to the llvm implementation of the MPI library.