Skip to content

Commit 9cbc404

Browse files
authored
ci : re-enable AVX512 testing (Windows-MSVC) (#584)
* CI: Re-enable AVX512 testing (Windows-MSVC) Now with 100% less base64 encoding * plain __cpuid is enough here
1 parent b51c717 commit 9cbc404

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.github/workflows/build.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,13 @@ jobs:
176176
if: ${{ matrix.build == 'avx512' }}
177177
continue-on-error: true
178178
run: |
179-
echo "TODO: check avx512f"
179+
cd build
180+
$vcdir = $(vswhere -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath)
181+
$msvc = $(join-path $vcdir $('VC\Tools\MSVC\'+$(gc -raw $(join-path $vcdir 'VC\Auxiliary\Build\Microsoft.VCToolsVersion.default.txt')).Trim()))
182+
$cl = $(join-path $msvc 'bin\Hostx64\x64\cl.exe')
183+
echo 'int main(void){unsigned int a[4];__cpuid(a,7);return !(a[1]&65536);}' >> avx512f.c
184+
& $cl /O2 /GS- /kernel avx512f.c /link /nodefaultlib /entry:main
185+
.\avx512f.exe && echo "AVX512F: YES" && ( echo HAS_AVX512F=1 >> $env:GITHUB_ENV ) || echo "AVX512F: NO"
180186
181187
- name: Test
182188
id: cmake_test

0 commit comments

Comments
 (0)