diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 03b91d0..af8cdbf 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -243,9 +243,6 @@ jobs: steps: - uses: actions/checkout@v4 - - uses: Jimver/cuda-toolkit@v0.2.16 - id: cuda-toolkit - - name: build shell: cmd run: | @@ -265,9 +262,6 @@ jobs: steps: - uses: actions/checkout@v4 - - uses: Jimver/cuda-toolkit@v0.2.16 - id: cuda-toolkit - - name: build shell: cmd run: | diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index d75cbd1..e180d91 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -1,6 +1,10 @@ cmake_minimum_required (VERSION 3.19) -project ("NvtxTests" LANGUAGES C CXX CUDA) +if(WIN32) + project("NvtxTests" LANGUAGES C CXX) +else() + project("NvtxTests" LANGUAGES C CXX CUDA) +endif() # Enforce standard C/C++ with sensible warnings and minimal compiler output on all platforms set(CMAKE_C_STANDARD 90) @@ -97,17 +101,21 @@ add_library(coveragec SHARED "CoverageC.c") target_link_libraries(coveragec PRIVATE nvtx3-c) set_target_properties(coveragec PROPERTIES C_VISIBILITY_PRESET hidden CXX_VISIBILITY_PRESET hidden) -add_library(coverage-cu SHARED "CoverageCuda.cu") -target_link_libraries(coverage-cu PRIVATE nvtx3-cpp) -set_target_properties(coverage-cu PROPERTIES C_VISIBILITY_PRESET hidden CXX_VISIBILITY_PRESET hidden) +if(NOT WIN32) + add_library(coverage-cu SHARED "CoverageCuda.cu") + target_link_libraries(coverage-cu PRIVATE nvtx3-cpp) + set_target_properties(coverage-cu PROPERTIES C_VISIBILITY_PRESET hidden CXX_VISIBILITY_PRESET hidden) +endif() add_library(coverage-mem SHARED "CoverageMem.c") target_link_libraries(coverage-mem PRIVATE nvtx3-c) set_target_properties(coverage-mem PROPERTIES C_VISIBILITY_PRESET hidden CXX_VISIBILITY_PRESET hidden) -add_library(coverage-memcudart SHARED "CoverageMemCudaRt.cu") -target_link_libraries(coverage-memcudart PRIVATE nvtx3-c) -set_target_properties(coverage-memcudart PROPERTIES C_VISIBILITY_PRESET hidden CXX_VISIBILITY_PRESET hidden) +if(NOT WIN32) + add_library(coverage-memcudart SHARED "CoverageMemCudaRt.cu") + target_link_libraries(coverage-memcudart PRIVATE nvtx3-c) + set_target_properties(coverage-memcudart PROPERTIES C_VISIBILITY_PRESET hidden CXX_VISIBILITY_PRESET hidden) +endif() add_library(coverage-payload SHARED "CoveragePayload.c") target_link_libraries(coverage-payload PRIVATE nvtx3-c) diff --git a/tests/runalltests.bat b/tests/runalltests.bat index 72f4974..aa20cb2 100755 --- a/tests/runalltests.bat +++ b/tests/runalltests.bat @@ -11,12 +11,12 @@ runtest.exe -t coveragec runtest.exe -t coveragec -i inj runtest.exe -t coverage-counter runtest.exe -t coverage-counter -i inj -runtest.exe -t coverage-cu -runtest.exe -t coverage-cu -i inj +:: runtest.exe -t coverage-cu +:: runtest.exe -t coverage-cu -i inj runtest.exe -t coverage-mem runtest.exe -t coverage-mem -i inj -runtest.exe -t coverage-memcudart -runtest.exe -t coverage-memcudart -i inj +:: runtest.exe -t coverage-memcudart +:: runtest.exe -t coverage-memcudart -i inj runtest.exe -t coverage-payload runtest.exe -t coverage-payload -i inj runtest.exe -t domains