Skip to content

Commit b18c11c

Browse files
authored
CMake: migrate cuSolverMp feature definitions after #7671 (#7697)
1 parent 4b6ce1c commit b18c11c

3 files changed

Lines changed: 3 additions & 6 deletions

File tree

cmake/modules/SetupCuBlasMp.cmake

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
include_guard(GLOBAL)
66

77
function(abacus_setup_cublasmp)
8-
abacus_add_feature_definitions(__CUBLASMP)
9-
108
# 1. Search for cuBLASMp library and header files
119
# libcublasmp.so
1210
find_library(CUBLASMP_LIBRARY NAMES cublasmp

cmake/modules/SetupCuSolverMp.cmake

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
include_guard(GLOBAL)
66

77
function(abacus_setup_cusolvermp)
8-
abacus_add_feature_definitions(__CUSOLVERMP)
9-
108
# Find cuSOLVERMp first, then decide communicator backend.
119
find_library(CUSOLVERMP_LIBRARY NAMES cusolverMp
1210
HINTS ${CAL_CUSOLVERMP_PATH} ${NVHPC_ROOT_DIR}
@@ -82,8 +80,6 @@ function(abacus_setup_cusolvermp)
8280
# - _use_cal=ON -> cal communicator backend
8381
# - _use_cal=OFF -> NCCL communicator backend
8482
if(_use_cal)
85-
abacus_add_feature_definitions(__USE_CAL)
86-
8783
find_library(CAL_LIBRARY NAMES cal
8884
HINTS ${CAL_CUSOLVERMP_PATH} ${NVHPC_ROOT_DIR}
8985
PATH_SUFFIXES lib lib64 math_libs/lib64)

source/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ set(_abacus_feature_definitions
5151
$<$<BOOL:${USE_CUDA}>:__CUDA>
5252
$<$<BOOL:${USE_CUDA}>:__UT_USE_CUDA>
5353
$<$<BOOL:${ENABLE_NCCL_PARALLEL_DEVICE}>:__NCCL_PARALLEL_DEVICE>
54+
$<$<BOOL:${ENABLE_CUSOLVERMP}>:__CUSOLVERMP>
55+
$<$<BOOL:${ENABLE_CUBLASMP}>:__CUBLASMP>
56+
$<$<BOOL:${_use_cal}>:__USE_CAL>
5457
$<$<BOOL:${USE_ROCM}>:__ROCM>
5558
$<$<BOOL:${USE_ROCM}>:__UT_USE_ROCM>
5659
$<$<BOOL:${USE_ROCM}>:__HIP_PLATFORM_HCC__>

0 commit comments

Comments
 (0)