Repository navigation
194 lines (190 loc) · 5.81 KB
/
Copy pathwindows.yml
File metadata and controls
194 lines (190 loc) · 5.81 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
name: Windows build
on: [push, pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.job }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-windows-x86:
name: 'MSVC ${{ matrix.os }}, ${{ matrix.target }} ${{ matrix.arch }}'
defaults:
run:
shell: bash {0}
strategy:
matrix:
os:
- 2022
- 2025
target:
- x86
- x64
arch:
- sse2
- avx
- avx2
- avx512bw
exclude:
# AVX on both platforms has a codegen error
# On 2019 in _mm256_rsqrt_ps, on 2022 in _mm256_blend_p*
- { arch: avx }
# On both platforms x86 + AVX512 triggers a compiler crash
- { target: x86, arch: avx512bw }
# /arch:SSE2 is not available on x64 platforms (SSE2 is enabled by default)
- { target: x64, arch: sse2 }
runs-on: windows-${{ matrix.os }}
steps:
- name: Setup compiler
uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{ matrix.target }}
- name: Setup Ninja
run: |
python3 -m pip install --upgrade pip setuptools wheel
python3 -m pip install ninja
- name: Checkout xsimd
uses: actions/checkout@v6
- name: Setup
run: |
cmake -B _build \
-DBUILD_TESTS=ON \
-DDOWNLOAD_DOCTEST=ON \
-DBUILD_BENCHMARK=ON \
-DBUILD_EXAMPLES=ON \
-DCMAKE_BUILD_TYPE=Release \
-DTARGET_ARCH=${{ matrix.arch }} \
-G Ninja
- name: Build
run: cmake --build _build
- name: Testing xsimd
if: ${{ !startsWith(matrix.arch, 'avx512') }}
env:
# Set CPU feature test expectations
# Assuming the runner always has AVX2 (independent of compilation option)
XSIMD_TEST_CPU_ASSUME_NEON64: "0"
XSIMD_TEST_CPU_ASSUME_SSE4_2: "1"
XSIMD_TEST_CPU_ASSUME_AVX2: "1"
XSIMD_TEST_CPU_ASSUME_MANUFACTURER: "intel,amd"
run: ./_build/test/test_xsimd
build-windows-mingw:
name: 'MSYS2 ${{ matrix.msystem }}'
runs-on: windows-2022
defaults:
run:
shell: msys2 {0}
strategy:
matrix:
# Temporarily remove MINGW64 and UCRT64 builds because
# GCC 12 gives an unexpected overflow warning for __builtin_memmove
# see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106199
msystem: [ MINGW32, CLANG64 ]
#msystem: [ MINGW32, MINGW64, UCRT64, CLANG32, CLANG64 ]
fail-fast: false
steps:
- name: Use MinGW from MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.msystem }}
update: true
path-type: minimal
pacboy: >-
cc:p
cmake:p
ninja:p
- name: Checkout xsimd
uses: actions/checkout@v6
- name: Configure
run: |
cmake -B _build \
-DBUILD_TESTS=ON \
-DBUILD_BENCHMARK=ON \
-DBUILD_EXAMPLES=ON \
-DCMAKE_BUILD_TYPE=Release \
-DDOWNLOAD_DOCTEST=ON \
-G Ninja
- name: Build
run: cmake --build _build
- name: Test
run: ./_build/test/test_xsimd
build-windows-clang-cl:
name: 'clang-cl x64 ${{ matrix.config.name }}'
defaults:
run:
shell: bash {0}
strategy:
matrix:
config:
- { name: "AVX2", arch: "avx2", flags: "", benchmark: "ON", examples: "ON" }
- { name: "/fp:fast", arch: "generic", flags: "/fp:fast", benchmark: "OFF", examples: "OFF" }
runs-on: windows-2025
steps:
- name: Setup compiler
uses: ilammy/msvc-dev-cmd@v1
with:
arch: amd64
- name: Check clang-cl
run: |
command -v clang-cl
clang-cl --version
- name: Setup Ninja
run: |
python3 -m pip install --upgrade pip setuptools wheel
python3 -m pip install ninja
- name: Checkout xsimd
uses: actions/checkout@v3
- name: Setup
run: |
cmake -B _build \
-DBUILD_TESTS=ON \
-DDOWNLOAD_DOCTEST=ON \
-DBUILD_BENCHMARK=${{ matrix.config.benchmark }} \
-DBUILD_EXAMPLES=${{ matrix.config.examples }} \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=clang-cl \
-DCMAKE_CXX_COMPILER=clang-cl \
-DTARGET_ARCH=${{ matrix.config.arch }} \
-DCMAKE_CXX_FLAGS="${{ matrix.config.flags }} -DXSIMD_REASSOCIATIVE_MATH=1" \
-G Ninja
- name: Build
run: cmake --build _build
- name: Testing xsimd
run: ./_build/test/test_xsimd
build-windows-arm64:
name: 'MSVC arm64 ${{ matrix.abi.name }}'
defaults:
run:
shell: bash {0}
strategy:
matrix:
abi:
- { name: "native", cflags: "" }
- { name: "arm64ec", cflags: " /arm64EC" }
runs-on: windows-11-arm
steps:
- name: Setup compiler
uses: ilammy/msvc-dev-cmd@v1
with:
arch: arm64
# MSVC 19.51 miscompiles the float log1p kernel on neon64
toolset: 14.44
- name: Setup Ninja
run: |
python3 -m pip install --upgrade pip setuptools wheel
python3 -m pip install ninja
- name: Checkout xsimd
uses: actions/checkout@v6
- name: Setup
run: |
cmake -B _build \
-DBUILD_TESTS=ON \
-DDOWNLOAD_DOCTEST=ON \
-DBUILD_BENCHMARK=ON \
-DBUILD_EXAMPLES=ON \
-DCMAKE_BUILD_TYPE=Release \
-DTARGET_ARCH=neon64 \
-G Ninja
env:
CFLAGS: ${{ matrix.abi.cflags }}
CXXFLAGS: ${{ matrix.abi.cflags }}
- name: Build
run: cmake --build _build
- name: Testing xsimd
run: ./_build/test/test_xsimd