diff --git a/.gitignore b/.gitignore index b79f0f5bd2..f7b730d792 100644 --- a/.gitignore +++ b/.gitignore @@ -94,6 +94,9 @@ dkms.conf ### CMake ### build*/ +# Spack +build-* + ### CMake Patch ### # External projects *-prefix/ diff --git a/CMakeLists.txt b/CMakeLists.txt index 8efd080806..46d4bf7722 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -250,6 +250,7 @@ set(CP2K_SUPPORTED_CUDA_ARCHITECTURES P100 V100 A100 + H100 A40) set(CP2K_SUPPORTED_HIP_ARCHITECTURES Mi50 @@ -263,6 +264,7 @@ set(CP2K_SUPPORTED_HIP_ARCHITECTURES P100 V100 A100 + H100 A40) set(CP2K_WITH_GPU @@ -513,6 +515,7 @@ if((CP2K_USE_ACCEL MATCHES CUDA) OR (CP2K_USE_ACCEL MATCHES HIP)) set(CP2K_GPU_ARCH_NUMBER_P100 60) set(CP2K_GPU_ARCH_NUMBER_V100 70) set(CP2K_GPU_ARCH_NUMBER_A100 80) + set(CP2K_GPU_ARCH_NUMBER_H100 90) set(CP2K_GPU_ARCH_NUMBER_A40 86) set(CP2K_GPU_ARCH_NUMBER_Mi50 gfx906) set(CP2K_GPU_ARCH_NUMBER_Mi100 gfx908) diff --git a/INSTALL.md b/INSTALL.md index 8e3bdfbedb..3c85f87301 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -191,7 +191,7 @@ required. multiplications. - Add `-lstdc++ -lcudart -lnvrtc -lcuda -lcublas` to LIBS. - Specify the GPU type (e.g., `GPUVER = P100`), possible values are K20X, K40, K80, P100, V100, - A100, A40. + A100, H100, A40. - Specify the C++ compiler (e.g., `CXX = g++`) and the CXXFLAGS to support the C++11 standard. - CUFFT 7.0 has a known bug and is therefore disabled by default. NVIDIA's webpage list a patch (an upgraded version cufft i.e. >= 7.0.35) - use this together with `-D__HAS_PATCHED_CUFFT_70`. diff --git a/tools/toolchain/install_cp2k_toolchain.sh b/tools/toolchain/install_cp2k_toolchain.sh index 41ea155c65..5517d7b688 100755 --- a/tools/toolchain/install_cp2k_toolchain.sh +++ b/tools/toolchain/install_cp2k_toolchain.sh @@ -462,12 +462,12 @@ while [ $# -ge 1 ]; do --gpu-ver=*) user_input="${1#*=}" case "${user_input}" in - K20X | K40 | K80 | P100 | V100 | A100 | A40 | Mi50 | Mi100 | Mi250 | no) + K20X | K40 | K80 | P100 | V100 | A100 | H100 | A40 | Mi50 | Mi100 | Mi250 | no) export GPUVER="${user_input}" ;; *) report_error ${LINENO} \ - "--gpu-ver currently only supports K20X, K40, K80, P100, V100, A100, A40, Mi50, Mi100, Mi250, and no as options" + "--gpu-ver currently only supports K20X, K40, K80, P100, V100, A100, H100, A40, Mi50, Mi100, Mi250, and no as options" exit 1 ;; esac @@ -947,6 +947,9 @@ case ${GPUVER} in A40) export ARCH_NUM="86" ;; + H100) + export ARCH_NUM="90" + ;; Mi50) # TODO: export ARCH_NUM= ;; @@ -961,7 +964,7 @@ case ${GPUVER} in ;; *) report_error ${LINENO} \ - "--gpu-ver currently only supports K20X, K40, K80, P100, V100, A100, A40, Mi50, Mi100, Mi250, and no as options" + "--gpu-ver currently only supports K20X, K40, K80, P100, V100, A100, H100, A40, Mi50, Mi100, Mi250, and no as options" exit 1 ;; esac diff --git a/tools/toolchain/scripts/stage8/install_spfft.sh b/tools/toolchain/scripts/stage8/install_spfft.sh index 960c98c32d..f97c4f4773 100755 --- a/tools/toolchain/scripts/stage8/install_spfft.sh +++ b/tools/toolchain/scripts/stage8/install_spfft.sh @@ -89,7 +89,7 @@ case "${with_spfft}" in if [ "$ENABLE_HIP" = "__TRUE__" ]; then case "${GPUVER}" in - K20X | K40 | K80 | P100 | V100 | A100 | A40) + K20X | K40 | K80 | P100 | V100 | A100 | A40 | H100) [ -d build-cuda ] && rm -rf "build-cuda" mkdir build-cuda cd build-cuda diff --git a/tools/toolchain/scripts/stage8/install_spla.sh b/tools/toolchain/scripts/stage8/install_spla.sh index f5e7d7fd40..878eac8782 100755 --- a/tools/toolchain/scripts/stage8/install_spla.sh +++ b/tools/toolchain/scripts/stage8/install_spla.sh @@ -77,7 +77,7 @@ case "${with_spla}" in if [ "$ENABLE_HIP" = "__TRUE__" ]; then case "${GPUVER}" in - K20X | K40 | K80 | P100 | V100 | A100 | A40) + K20X | K40 | K80 | P100 | V100 | A100 | A40 | H100) [ -d build-cuda ] && rm -rf "build-cuda" mkdir build-cuda cd build-cuda