Skip to content

[Offload] Fix disabling of cuda target on unsupported platforms #106835

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 31, 2024

Conversation

xen0n
Copy link
Contributor

@xen0n xen0n commented Aug 31, 2024

The target name and the message are wrong -- both should say "cuda" for the filtering to work.

Fixes commit 300e5b9 (#93186).

The target name and the message are wrong -- both should say "cuda" for
the filtering to work.

Fixes commit 300e5b9 (llvm#93186).
@llvmbot
Copy link
Member

llvmbot commented Aug 31, 2024

@llvm/pr-subscribers-offload

Author: WÁNG Xuěruì (xen0n)

Changes

The target name and the message are wrong -- both should say "cuda" for the filtering to work.

Fixes commit 300e5b9 (#93186).


Full diff: https://github.com/llvm/llvm-project/pull/106835.diff

1 Files Affected:

  • (modified) offload/CMakeLists.txt (+2-2)
diff --git a/offload/CMakeLists.txt b/offload/CMakeLists.txt
index 4cd97a6a5ff63d..d91b5fa1959295 100644
--- a/offload/CMakeLists.txt
+++ b/offload/CMakeLists.txt
@@ -159,8 +159,8 @@ if(NOT (CMAKE_SYSTEM_PROCESSOR MATCHES "(x86_64)|(ppc64le)|(aarch64)$"
                    "Linux x86_64, ppc64le, or aarch64 hosts")
     list(REMOVE_ITEM LIBOMPTARGET_PLUGINS_TO_BUILD "amdgpu")
   endif()
-  if("nvptx" IN_LIST LIBOMPTARGET_PLUGINS_TO_BUILD)
-    message(STATUS "Not building CUDA plugin: only support AMDGPU in "
+  if("cuda" IN_LIST LIBOMPTARGET_PLUGINS_TO_BUILD)
+    message(STATUS "Not building CUDA plugin: only support CUDA in "
                    "Linux x86_64, ppc64le, or aarch64 hosts")
     list(REMOVE_ITEM LIBOMPTARGET_PLUGINS_TO_BUILD "cuda")
   endif()

@jhuber6 jhuber6 merged commit 75545b3 into llvm:main Aug 31, 2024
8 checks passed
@xen0n xen0n deleted the fix-offload-cmake-cuda branch August 31, 2024 13:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants