Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

Commit

Permalink
Update more CUDA compiler ID checks.
Browse files Browse the repository at this point in the history
  • Loading branch information
alliepiper committed Jun 6, 2023
1 parent 9d4a366 commit 1d94385
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cmake/CubBuildCompilerTargets.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
6 changes: 3 additions & 3 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -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()
Expand Down Expand Up @@ -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()
Expand Down Expand Up @@ -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()

Expand Down

0 comments on commit 1d94385

Please sign in to comment.