File tree Expand file tree Collapse file tree 2 files changed +75
-0
lines changed Expand file tree Collapse file tree 2 files changed +75
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CMake
2+
3+ on :
4+ workflow_call :
5+ inputs :
6+ cuda-version :
7+ required : true
8+ type : string
9+
10+ env :
11+ # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
12+ BUILD_TYPE : Debug
13+
14+ jobs :
15+ build :
16+ # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
17+ # You can convert this to a matrix build if you need cross-platform coverage.
18+ # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
19+ runs-on : ubuntu-latest
20+
21+ steps :
22+ - uses : Jimver/cuda-toolkit@v0.2.11
23+ id : cuda-toolkit
24+ with :
25+ method : network
26+ sub-packages : ' ["nvcc"]'
27+ cuda : ${{ inputs.cuda-version }}
28+
29+ - uses : actions/checkout@v3
30+ with :
31+ submodules : ' true'
32+
33+ - name : Configure CMake
34+ # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
35+ # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
36+ run : cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DKERNEL_FLOAT_BUILD_TEST=1 -DKERNEL_FLOAT_BUILD_EXAMPLE=1
37+
38+ - name : Build
39+ # Build your program with the given configuration
40+ run : cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
41+
42+ - name : Test
43+ working-directory : ${{github.workspace}}/build
44+ # Execute tests defined by the CMake configuration.
45+ # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
46+ run : ./tests/kernel_float_tests --durations=yes --success --verbosity=high ~[GPU]
47+
Original file line number Diff line number Diff line change 1+ name : CMake
2+
3+ on :
4+ push :
5+ pull_request :
6+ branches : [ "main" ]
7+
8+ env :
9+ # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
10+ BUILD_TYPE : Debug
11+
12+ jobs :
13+ build-cuda :
14+ uses : ./.github/workflows/cmake-action.yml
15+ with :
16+ cuda-version : " 12.2.0"
17+
18+ build-cuda-11-7 :
19+ needs : build-cuda
20+ uses : ./.github/workflows/cmake-action.yml
21+ with :
22+ cuda-version : " 11.7.0"
23+
24+ build-cuda-12-0 :
25+ needs : build-cuda
26+ uses : ./.github/workflows/cmake-action.yml
27+ with :
28+ cuda-version : " 12.0.0"
You can’t perform that action at this time.
0 commit comments