[Openmp-commits] [openmp] 420d2fc - [OpenMP][CUDA] Get rid of redundant macro def
Shao-Ce SUN via Openmp-commits
openmp-commits at lists.llvm.org
Sat Mar 4 10:02:09 PST 2023
Author: Shao-Ce SUN
Date: 2023-03-05T02:01:59+08:00
New Revision: 420d2fcac9ceb0abedaa092002e89ef7a548af30
URL: https://github.com/llvm/llvm-project/commit/420d2fcac9ceb0abedaa092002e89ef7a548af30
DIFF: https://github.com/llvm/llvm-project/commit/420d2fcac9ceb0abedaa092002e89ef7a548af30.diff
LOG: [OpenMP][CUDA] Get rid of redundant macro def
Resolve warning of `TARGET_NAME` macro redefinition.
Reviewed By: jhuber6
Differential Revision: https://reviews.llvm.org/D145307
Added:
Modified:
openmp/libomptarget/plugins/cuda/dynamic_cuda/cuda.cpp
Removed:
################################################################################
diff --git a/openmp/libomptarget/plugins/cuda/dynamic_cuda/cuda.cpp b/openmp/libomptarget/plugins/cuda/dynamic_cuda/cuda.cpp
index 8f9ccec4e73b2..2271b3aa90ddd 100644
--- a/openmp/libomptarget/plugins/cuda/dynamic_cuda/cuda.cpp
+++ b/openmp/libomptarget/plugins/cuda/dynamic_cuda/cuda.cpp
@@ -85,8 +85,12 @@ DLWRAP_FINALIZE()
#define DYNAMIC_CUDA_PATH "libcuda.so"
#endif
+#ifndef TARGET_NAME
#define TARGET_NAME CUDA
+#endif
+#ifndef DEBUG_PREFIX
#define DEBUG_PREFIX "Target " GETNAME(TARGET_NAME) " RTL"
+#endif
static bool checkForCUDA() {
// return true if dlopen succeeded and all functions found
More information about the Openmp-commits
mailing list