-
-
Notifications
You must be signed in to change notification settings - Fork 13
296 lines (290 loc) · 9.08 KB
/
release.yml
File metadata and controls
296 lines (290 loc) · 9.08 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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
name: Benchmark Release
on:
push:
tags:
- 'v*.*.*'
- '!v*.*.*d'
workflow_dispatch:
jobs:
build_linux:
name: Build for linux
runs-on: ${{ matrix.os }}
continue-on-error: true
strategy:
max-parallel: 8
matrix:
arch: [DEIGEN_DONT_VECTORIZE, msse2, mavx, mavx2]
eigenversion: [3.3.4, 3.3.5, 3.3.6, 3.3.7, 3.3.8, 3.3.9, 3.4.0, 5.0.0]
os: [ubuntu-22.04, ubuntu-24.04]
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install dependencies
run: |
git clone https://gitlab.com/libeigen/eigen
pushd eigen
git checkout tags/${{ matrix.eigenversion }}
popd
mv eigen include
- name: Set C++ standard for Eigen 5.x
id: cxx_standard
run: |
if [[ "${{ matrix.eigenversion }}" == 5.* ]]; then
echo "cxx_standard=14" >> $GITHUB_OUTPUT
else
echo "cxx_standard=11" >> $GITHUB_OUTPUT
fi
- name: Build
run: |
export EIGEN_PATH=`pwd`/include
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=${{ steps.cxx_standard.outputs.cxx_standard }} -DEIGENRAND_CXX_FLAGS="-${{ matrix.arch }} -I${EIGEN_PATH}" ../
make
- name: CPU info
run: cat /proc/cpuinfo
- name: Run Bench
run: |
./build/EigenRand-benchmark
- name: Run BenchMv
run: |
./build/EigenRand-benchmark-mv
- name: Run BenchVop
run: |
./build/EigenRand-benchmark-vop
- name: Run Accuracy
run: |
./build/EigenRand-accuracy
- name: Set up Python3
uses: actions/setup-python@v1
with:
python-version: "3.10"
- name: Test Reference
run: |
pip install scipy
python benchmark/comp_scipy.py
build_macos:
name: Build for macOS (Intel)
runs-on: macos-15-intel
continue-on-error: true
strategy:
max-parallel: 8
matrix:
arch: [DEIGEN_DONT_VECTORIZE, msse2, mavx]
eigenversion: [3.3.5, 3.3.6, 3.3.7, 3.3.8, 3.3.9, 3.4.0, 5.0.0]
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install dependencies
run: |
wget https://gitlab.com/libeigen/eigen/-/archive/${{ matrix.eigenversion }}/eigen-${{ matrix.eigenversion }}.tar.gz
tar -zxvf eigen-${{ matrix.eigenversion }}.tar.gz
mv eigen-${{ matrix.eigenversion }} include
- name: Set C++ standard for Eigen 5.x
id: cxx_standard
run: |
if [[ "${{ matrix.eigenversion }}" == 5.* ]]; then
echo "cxx_standard=14" >> $GITHUB_OUTPUT
else
echo "cxx_standard=11" >> $GITHUB_OUTPUT
fi
- name: Build
run: |
export EIGEN_PATH=`pwd`/include
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=${{ steps.cxx_standard.outputs.cxx_standard }} -DEIGENRAND_CXX_FLAGS="-${{ matrix.arch }} -I${EIGEN_PATH}" ../
make
- name: CPU info
run: sysctl -a | grep machdep.cpu
- name: Run Bench
continue-on-error: true
run: |
./build/EigenRand-benchmark
- name: Run BenchMv
continue-on-error: true
run: |
./build/EigenRand-benchmark-mv
- name: Run BenchVop
continue-on-error: true
run: |
./build/EigenRand-benchmark-vop
- name: Run Accuracy
run: |
./build/EigenRand-accuracy
- name: Set up Python3
uses: actions/setup-python@v1
with:
python-version: "3.10"
- name: Test Reference
run: |
pip install scipy
python benchmark/comp_scipy.py
build_windows:
name: Build for Windows
runs-on: windows-2022
continue-on-error: true
strategy:
max-parallel: 8
matrix:
arch: ['/D EIGEN_DONT_VECTORIZE', '/arch:SSE2', '/arch:AVX', '/arch:AVX2']
eigenversion: [3.3.4, 3.3.5, 3.3.6, 3.3.7, 3.3.8, 3.3.9, 3.4.0, 5.0.0]
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install dependencies
run: |
Invoke-WebRequest -OutFile eigen.tar.gz https://gitlab.com/libeigen/eigen/-/archive/${{ matrix.eigenversion }}/eigen-${{ matrix.eigenversion }}.tar.gz
tar -zxvf eigen.tar.gz
mv eigen-${{ matrix.eigenversion }} include
echo "EIGEN_PATH=$(Get-Location)\include" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append
- name: Set C++ standard for Eigen 5.x
id: cxx_standard
shell: pwsh
run: |
if ("${{ matrix.eigenversion }}" -like "5.*") {
echo "cxx_standard=14" >> $env:GITHUB_OUTPUT
} else {
echo "cxx_standard=11" >> $env:GITHUB_OUTPUT
}
- name: Build
run: |
cmake -B build -G "Visual Studio 17 2022" -A x64 -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=${{ steps.cxx_standard.outputs.cxx_standard }} -DEIGENRAND_CXX_FLAGS="${{ matrix.arch }} /I${{ env.EIGEN_PATH }}"
cmake --build build --config Release
- name: CPU info
run: bash -c "cat /proc/cpuinfo"
- name: Run Bench
run: |
.\build\Release\EigenRand-benchmark.exe
- name: Run BenchMv
run: |
.\build\Release\EigenRand-benchmark-mv.exe
- name: Run BenchVop
run: |
.\build\Release\EigenRand-benchmark-vop.exe
- name: Run Accuracy
run: |
.\build\Release\EigenRand-accuracy.exe
- name: Set up Python3
uses: actions/setup-python@v1
with:
python-version: "3.10"
- name: Test Reference
run: |
pip install scipy
python benchmark/comp_scipy.py
build_linux_arm64:
name: Build for linux (Arm64)
runs-on: ${{ matrix.os }}
continue-on-error: true
strategy:
max-parallel: 8
matrix:
arch: [DEIGEN_DONT_VECTORIZE, march=armv8-a+simd]
eigenversion: [3.3.4, 3.3.5, 3.3.6, 3.3.7, 3.3.8, 3.3.9, 3.4.0, 5.0.0]
os: [ubuntu-22.04-arm64, ubuntu-24.04-arm64]
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install dependencies
run: |
git clone https://gitlab.com/libeigen/eigen
pushd eigen
git checkout tags/${{ matrix.eigenversion }}
popd
mv eigen include
- name: Set C++ standard for Eigen 5.x
id: cxx_standard
run: |
if [[ "${{ matrix.eigenversion }}" == 5.* ]]; then
echo "cxx_standard=14" >> $GITHUB_OUTPUT
else
echo "cxx_standard=11" >> $GITHUB_OUTPUT
fi
- name: Build
run: |
export EIGEN_PATH=`pwd`/include
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=${{ steps.cxx_standard.outputs.cxx_standard }} -DEIGENRAND_CXX_FLAGS="-${{ matrix.arch }} -I${EIGEN_PATH}" ../
make
- name: CPU info
run: cat /proc/cpuinfo
- name: Run Bench
run: |
./build/EigenRand-benchmark
- name: Run BenchMv
run: |
./build/EigenRand-benchmark-mv
- name: Run BenchVop
run: |
./build/EigenRand-benchmark-vop
- name: Run Accuracy
run: |
./build/EigenRand-accuracy
- name: Set up Python3
uses: actions/setup-python@v1
with:
python-version: "3.10"
- name: Test Reference
run: |
pip install scipy
python benchmark/comp_scipy.py
build_macos_arm64:
name: Build for macOS (Arm64)
runs-on: macos-15
continue-on-error: true
strategy:
max-parallel: 8
matrix:
arch: [DEIGEN_DONT_VECTORIZE, march=armv8-a+simd]
eigenversion: [3.3.5, 3.3.6, 3.3.7, 3.3.8, 3.3.9, 3.4.0, 5.0.0]
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install dependencies
run: |
wget https://gitlab.com/libeigen/eigen/-/archive/${{ matrix.eigenversion }}/eigen-${{ matrix.eigenversion }}.tar.gz
tar -zxvf eigen-${{ matrix.eigenversion }}.tar.gz
mv eigen-${{ matrix.eigenversion }} include
- name: Set C++ standard for Eigen 5.x
id: cxx_standard
run: |
if [[ "${{ matrix.eigenversion }}" == 5.* ]]; then
echo "cxx_standard=14" >> $GITHUB_OUTPUT
else
echo "cxx_standard=11" >> $GITHUB_OUTPUT
fi
- name: Build
run: |
export EIGEN_PATH=`pwd`/include
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_STANDARD=${{ steps.cxx_standard.outputs.cxx_standard }} -DEIGENRAND_CXX_FLAGS="-${{ matrix.arch }} -I${EIGEN_PATH}" ../
make
- name: CPU info
run: sysctl -a | grep machdep.cpu
- name: Run Bench
continue-on-error: true
run: |
./build/EigenRand-benchmark
- name: Run BenchMv
continue-on-error: true
run: |
./build/EigenRand-benchmark-mv
- name: Run BenchVop
continue-on-error: true
run: |
./build/EigenRand-benchmark-vop
- name: Run Accuracy
run: |
./build/EigenRand-accuracy
- name: Set up Python3
uses: actions/setup-python@v1
with:
python-version: "3.10"
- name: Test Reference
run: |
pip install scipy
python benchmark/comp_scipy.py