Use TARGET_DIRECTORY for Kron.cpp CUDA property#710
Use TARGET_DIRECTORY for Kron.cpp CUDA property#710ultimatile wants to merge 1 commit intoCytnx-dev:masterfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #710 +/- ##
=======================================
Coverage 30.19% 30.19%
=======================================
Files 215 215
Lines 38335 38335
Branches 15474 15474
=======================================
Hits 11576 11576
Misses 24858 24858
Partials 1901 1901 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
I wonder why CMAKE_SOURCE_DIR doesn't cover the file. |
|
Sorry for the late response. I needed some time to investigate why Both
|
Building
src/linalg/Kron.cppfor GPU should be handled bynvcc(or another CUDA-family compiler).However, under the current configuration, the
LANGUAGE CUDAproperty does not propagate to the top-level CMake configuration, causing the file to be compiled incorrectly with a C++ compiler such asg++.This PR corrects the issue by using
TARGET_DIRECTORY, enablingKron.cppto be built properly withnvcc.This fix may also resolve the ordering issue mentioned in the comment.