diff options
-rw-r--r-- | Modules/FindCUDA/select_compute_arch.cmake | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/Modules/FindCUDA/select_compute_arch.cmake b/Modules/FindCUDA/select_compute_arch.cmake index 8fb44d8..b604a17 100644 --- a/Modules/FindCUDA/select_compute_arch.cmake +++ b/Modules/FindCUDA/select_compute_arch.cmake @@ -30,12 +30,17 @@ endif () if (CUDA_VERSION VERSION_GREATER "7.5") list(APPEND CUDA_KNOWN_GPU_ARCHITECTURES "Pascal") - list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "6.0" "6.1" "6.1+PTX") + list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "6.0" "6.1") else() list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "5.2+PTX") endif () - +if (CUDA_VERSION VERSION_GREATER "8.5") + list(APPEND CUDA_KNOWN_GPU_ARCHITECTURES "Volta") + list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "7.0" "7.0+PTX") +else() + list(APPEND CUDA_COMMON_GPU_ARCHITECTURES "6.1+PTX") +endif() ################################################################################################ # A function for automatic detection of GPUs installed (if autodetection is enabled) @@ -141,6 +146,9 @@ function(CUDA_SELECT_NVCC_ARCH_FLAGS out_variable) elseif(${arch_name} STREQUAL "Pascal") set(arch_bin 6.0 6.1) set(arch_ptx 6.1) + elseif(${arch_name} STREQUAL "Volta") + set(arch_bin 7.0 7.0) + set(arch_ptx 7.0) else() message(SEND_ERROR "Unknown CUDA Architecture Name ${arch_name} in CUDA_SELECT_NVCC_ARCH_FLAGS") endif() |