Skip to content
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

Fix: storage_gpu for HIPCC-AMDGPU #1540

Merged
merged 2 commits into from
Aug 6, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions cmake/public/gridtools_setup_targets.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -249,9 +249,12 @@ macro(_gt_setup_targets _config_mode clang_cuda_mode)
endif()

find_package(CUDAToolkit)
if(CUDAToolkit_FOUND)
if(CUDAToolkit_FOUND OR GT_CUDA_TYPE STREQUAL HIPCC-AMDGPU)
_gt_add_library(${_config_mode} storage_gpu)
target_link_libraries(${_gt_namespace}storage_gpu INTERFACE ${_gt_namespace}gridtools CUDA::cudart)
target_link_libraries(${_gt_namespace}storage_gpu INTERFACE ${_gt_namespace}gridtools)
if(CUDAToolkit_FOUND)
target_link_libraries(${_gt_namespace}storage_gpu INTERFACE CUDA::cudart)
endif()
list(APPEND GT_STORAGES gpu)
endif()

Expand Down