Add support for OpenACC
nchaimov opened this issue · comments
TAU now supports OpenACC with PGI/nvhpc compilers. To test this in TAU:
- Log in to a system that has compatible compilers, such as voltar.nic.uoregon.edu
- Load the appropriate compiler module, e.g.,
module load nvhpc/20.9
- Load CUDA:
module load cuda/11.4
- Build TAU with
-openacc -cc=nvc -c++=nvc++ -fortran=nvfortran -cuda=/packages/cuda/11.4 -bfd=download -unwind=download; make install -j8
cd examples/openacc
make
tau_exec -T serial,acc,nvhpc,cupti -openacc -cupti ./jacobi
We want to support this TAU configuration in TAU Commander. Adding this support will involve:
- Adding a boolean OpenACC argument to the Application model, indicating whether the application uses OpenACC; see for example
taucmdr/packages/taucmdr/model/application.py
Lines 75 to 87 in eae3ae7
- Adding a similar argument to the Measurement to control whether to measure OpenACC. A constraint should be on this requiring that the Application use OpenACC and that a compatible compiler be used. See
taucmdr/packages/taucmdr/model/measurement.py
Lines 183 to 193 in eae3ae7
- Modifying
tau_installation.py
to build TAU with-openacc
when the Application specifies OpenACC. - Modifying
tau_installation.py
to expect the tagacc
when TAU is built with OpenACC. - Modifying
tau_installation.py
to run applications throughtau_exec
with-openacc
when the Measurement specifies OpenACC. - Adding a test of OpenACC support to the test suite and verifying that it passes on a system that supports OpenACC. The test should be configured so that it will not run if the system doesn't have an appropriate compiler.
One other probable task for this: the PGI compilers have been re-named and are now the NVHPC compilers. They used to be in executables named pgcc
, pgCC
, and pgfortran
but are now nvc
, nvc++
, and nvfortran
. The compiler detection logic in TAU Commander will probably need to be updated to support the new names. The existing code for detection of PGI compilers is at:
taucmdr/packages/taucmdr/cf/compiler/host.py
Lines 48 to 49 in eae3ae7
Also, the tag that is used with TAU is now nvhpc
instead of pgi
when the new versions are used, so the logic to construct a tag from the compiler will also need to be updated. That is at:
taucmdr/packages/taucmdr/cf/software/tau_installation.py
Lines 1037 to 1039 in eae3ae7
Added in #416. Thanks @vikram8128!