diff options
author | Robert Maynard <robert.maynard@kitware.com> | 2019-08-27 17:52:55 (GMT) |
---|---|---|
committer | Robert Maynard <robert.maynard@kitware.com> | 2019-09-05 14:51:02 (GMT) |
commit | 2d7bb13da7ec13ce73facaff07847d75d8a20e91 (patch) | |
tree | 5f82719ebe153140ea44c93a1c6b7a49c1062be9 /Tests/CudaOnly/ResolveDeviceSymbols/file2.cu | |
parent | 09032f09f8d2b4f7af658060ef434083f9d6a0d4 (diff) | |
download | CMake-2d7bb13da7ec13ce73facaff07847d75d8a20e91.zip CMake-2d7bb13da7ec13ce73facaff07847d75d8a20e91.tar.gz CMake-2d7bb13da7ec13ce73facaff07847d75d8a20e91.tar.bz2 |
CUDA: static lib device linking computes required static libs
Previously the CMake didn't compute the required set of libraries
needed to properly device link a static library when
CUDA_RESOLVE_DEVICE_SYMBOLS was enabled.
Diffstat (limited to 'Tests/CudaOnly/ResolveDeviceSymbols/file2.cu')
-rw-r--r-- | Tests/CudaOnly/ResolveDeviceSymbols/file2.cu | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/Tests/CudaOnly/ResolveDeviceSymbols/file2.cu b/Tests/CudaOnly/ResolveDeviceSymbols/file2.cu index 278fd6c..0e5e7aa 100644 --- a/Tests/CudaOnly/ResolveDeviceSymbols/file2.cu +++ b/Tests/CudaOnly/ResolveDeviceSymbols/file2.cu @@ -1,25 +1,9 @@ #include "file2.h" -result_type __device__ file1_func(int x); - result_type_dynamic __device__ file2_func(int x) { const result_type r = file1_func(x); const result_type_dynamic rd{ r.input, r.sum, true }; return rd; } - -static __global__ void file2_kernel(result_type_dynamic& r, int x) -{ - // call static_func which is a method that is defined in the - // static library that is always out of date - r = file2_func(x); -} - -int file2_launch_kernel(int x) -{ - result_type_dynamic r; - file2_kernel<<<1, 1>>>(r, x); - return r.sum; -} |