From 1d94385d0fbecf60c29414903e761d6b14758560 Mon Sep 17 00:00:00 2001 From: Allison Vacanti Date: Tue, 6 Jun 2023 17:14:00 -0400 Subject: [PATCH] Update more CUDA compiler ID checks. --- cmake/CubBuildCompilerTargets.cmake | 2 +- test/CMakeLists.txt | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cmake/CubBuildCompilerTargets.cmake b/cmake/CubBuildCompilerTargets.cmake index 0b868f97f..5725496a5 100644 --- a/cmake/CubBuildCompilerTargets.cmake +++ b/cmake/CubBuildCompilerTargets.cmake @@ -83,7 +83,7 @@ function(cub_build_compiler_targets) endif() endif() - if ("NVCXX" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") + if ("NVHPC" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") list(APPEND cxx_compile_options -Mnodaz) # TODO: Managed memory is currently not supported on windows with WSL list(APPEND cxx_compile_options -gpu=nomanaged) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 7b73201c4..bf31f67b4 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -1,4 +1,4 @@ -if ("NVCXX" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") +if ("NVHPC" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") # NVBugs 200770766 set(CUB_SEPARATE_CATCH2 ON) else() @@ -152,7 +152,7 @@ function(cub_add_test target_name_var test_name test_src cub_target) PROPERTY POSITION_INDEPENDENT_CODE ON ) - if ("NVCXX" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") + if ("NVHPC" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") target_link_options(${config_c2h_target} PRIVATE "-cuda") target_compile_options(${config_c2h_target} PRIVATE "-fPIC") endif() @@ -195,7 +195,7 @@ function(cub_add_test target_name_var test_name test_src cub_target) target_include_directories(${config_c2run_target} PRIVATE "${CUB_SOURCE_DIR}/test" ) - if ("NVCXX" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") + if ("NVHPC" STREQUAL "${CMAKE_CUDA_COMPILER_ID}") target_link_options(${config_c2run_target} PRIVATE "-cuda") endif()