Repository navigation
114 lines (96 loc) · 3.04 KB
/
Copy pathbuild.yml
File metadata and controls
114 lines (96 loc) · 3.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
name: Build
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
jobs:
build-cuda:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-2022]
cuda: ["12.4.0", "12.5.0", "12.6.0", "12.8.0", "12.9.0", "13.0.0", "13.1.0"]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: Jimver/cuda-toolkit@v0.2.30
id: cuda-toolkit
with:
cuda: ${{ matrix.cuda }}
linux-local-args: '["--toolkit"]'
use-github-cache: 'false'
log-file-suffix: '${{ matrix.os }}-${{ matrix.cuda }}'
- name: CUDA info
run: |
echo "Installed cuda version is: ${{ steps.cuda-toolkit.outputs.cuda }}"
echo "Cuda install location: ${{ steps.cuda-toolkit.outputs.CUDA_PATH }}"
nvcc -V
- name: Install build deps (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y ninja-build zlib1g-dev
- name: Configure (Linux)
if: runner.os == 'Linux'
run: |
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=Release \
-DCUPDLPX_BUILD_TESTS=OFF
- name: Build (Linux)
if: runner.os == 'Linux'
run: |
cmake --build build --clean-first
- name: Configure (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
cmake -B build `
-DCMAKE_CONFIGURATION_TYPES=Release `
-DCUPDLPX_BUILD_TESTS=OFF
- name: Build (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
cmake --build build --clean-first --config Release
build-hip:
name: build-hip (rocm ${{ matrix.rocm }})
strategy:
fail-fast: false
matrix:
rocm: ["7.2", "7.2.4"]
runs-on: ubuntu-latest
container:
image: rocm/dev-ubuntu-22.04:${{ matrix.rocm }}
env:
DEBIAN_FRONTEND: noninteractive
steps:
# actions/checkout needs git, which the ROCm dev image does not ship with.
- name: Install checkout prerequisites
run: |
apt-get update
apt-get install -y --no-install-recommends git ca-certificates
- uses: actions/checkout@v4
- name: Install build deps
run: |
apt-get install -y --no-install-recommends \
cmake ninja-build zlib1g-dev \
hipblas-dev hipsparse-dev hipcub-dev rocprim-dev
# The ROCm apt packages don't add /opt/rocm/bin to PATH for non-interactive shells.
- name: Add ROCm to PATH
run: echo "/opt/rocm/bin" >> "$GITHUB_PATH"
- name: HIP info
run: |
hipcc --version
- name: Configure
run: |
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=Release \
-DCUPDLPX_BUILD_TESTS=OFF \
-DUSE_HIP=ON \
-DCMAKE_HIP_ARCHITECTURES=gfx90a \
-DCMAKE_PREFIX_PATH=/opt/rocm
- name: Build
run: |
cmake --build build --clean-first