File tree Expand file tree Collapse file tree 2 files changed +52
-0
lines changed Expand file tree Collapse file tree 2 files changed +52
-0
lines changed Original file line number Diff line number Diff line change 1+ #===-- lib/flang_rt/CUDA/CMakeLists.txt ------------------------------------===#
2+ #
3+ # Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ # See https://llvm.org/LICENSE.txt for license information.
5+ # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ #
7+ #===------------------------------------------------------------------------===#
8+
9+
10+ add_flangrt_library(CufRuntime STATIC
11+ allocatable.cpp
12+ allocator.cpp
13+ descriptor.cpp
14+ kernel.cpp
15+ memmove-function.cpp
16+ memory.cpp
17+ registration.cpp
18+ )
19+
20+ # libCufRuntime depends on a certain version of CUDA. To be able to have
21+ # multiple build of this library with different CUDA version, the version is
22+ # added to the library name.
23+ set_target_properties (CufRuntime
24+ PROPERTIES
25+ OUTPUT_NAME "CufRuntime_cuda_${CUDAToolkit_VERSION_MAJOR} "
26+ )
27+
28+ target_include_directories (CufRuntime PRIVATE ${CUDAToolkit_INCLUDE_DIRS} )
29+
30+ target_link_libraries (CufRuntime
31+ PUBLIC
32+ flang_rt
33+ CUDA::cudart_static
34+ )
Original file line number Diff line number Diff line change 1+ #===-- unittests/Runtime/CUDA/CMakeLists.txt -------------------------------===#
2+ #
3+ # Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+ # See https://llvm.org/LICENSE.txt for license information.
5+ # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+ #
7+ #===------------------------------------------------------------------------===#
8+
9+ add_flangrt_unittest(FlangCufRuntimeTests
10+ Allocatable.cpp
11+ AllocatorCUF.cpp
12+ Memory.cpp
13+ )
14+
15+ target_link_libraries (FlangCufRuntimeTests
16+ PRIVATE
17+ CufRuntime
18+ )
You can’t perform that action at this time.
0 commit comments