New compiler: nvhpc (NVIDIA HPC SDK) (#19294)

* Add nvhpc compiler definition: "spack compiler add" will now look
  for instances of the NVIDIA HPC SDK compiler executables
  (nvc, nvc++, nvfortran) in supplied paths
* Add the nvhpc package which installs the nvhpc compiler
* Add testing for nvhpc detection and C++-standard/pic flags

Co-authored-by: Scott McMillan <smcmillan@nvidia.com>
This commit is contained in:
Scott McMillan
2020-10-16 16:04:27 -05:00
committed by GitHub
parent 78f349c635
commit a612be1c98
8 changed files with 307 additions and 3 deletions

6
lib/spack/env/cc vendored
View File

@@ -107,19 +107,19 @@ case "$command" in
cpp)
mode=cpp
;;
cc|c89|c99|gcc|clang|armclang|icc|pgcc|xlc|xlc_r|fcc)
cc|c89|c99|gcc|clang|armclang|icc|pgcc|nvc|xlc|xlc_r|fcc)
command="$SPACK_CC"
language="C"
comp="CC"
lang_flags=C
;;
c++|CC|g++|clang++|armclang++|icpc|pgc++|xlc++|xlc++_r|FCC)
c++|CC|g++|clang++|armclang++|icpc|pgc++|nvc++|xlc++|xlc++_r|FCC)
command="$SPACK_CXX"
language="C++"
comp="CXX"
lang_flags=CXX
;;
ftn|f90|fc|f95|gfortran|flang|armflang|ifort|pgfortran|xlf90|xlf90_r|nagfor|frt)
ftn|f90|fc|f95|gfortran|flang|armflang|ifort|pgfortran|nvfortran|xlf90|xlf90_r|nagfor|frt)
command="$SPACK_FC"
language="Fortran 90"
comp="FC"

1
lib/spack/env/nvhpc/nvc vendored Symbolic link
View File

@@ -0,0 +1 @@
../cc

1
lib/spack/env/nvhpc/nvc++ vendored Symbolic link
View File

@@ -0,0 +1 @@
../cc

1
lib/spack/env/nvhpc/nvfortran vendored Symbolic link
View File

@@ -0,0 +1 @@
../cc