Skip to content

Commit dde614b

Browse files
committed
enable SSE
1 parent bab4d0a commit dde614b

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

quaddtype/reinstall.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
#!/bin/bash
22
set -x
33

4-
if [ -d "build/" ]; then
5-
rm -r build
6-
rm -rf dist/
7-
rm -rf subprojects/qblas
8-
rm -rf subprojects/sleef
9-
fi
4+
# Always clean build artifacts and subprojects
5+
rm -rf build/
6+
rm -rf dist/
7+
rm -rf subprojects/qblas
8+
rm -rf subprojects/sleef
9+
rm -rf .mesonpy-*
1010

1111
python -m pip uninstall -y numpy_quaddtype
1212
python -m pip install . -vv --no-build-isolation 2>&1 | tee build_log.txt

quaddtype/subprojects/packagefiles/sleef/meson.build

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ if host_machine.system() == 'windows'
1313
endif
1414

1515
# For building sleef with TSan, delete the sleef subproject and follow the README instructions to build sleef externally.
16+
# Enable SIMD extensions that are OFF by default but required by qblas (will change in future)
17+
sleef_simd_flags = []
18+
if host_machine.cpu_family() == 'x86_64' or host_machine.cpu_family() == 'x86'
19+
sleef_simd_flags = ['-DSLEEF_ENABLE_SSE2=ON']
20+
endif
21+
1622
sleef_configure = run_command([
1723
cmake,
1824
'-S', meson.current_source_dir(),
@@ -24,7 +30,7 @@ sleef_configure = run_command([
2430
'-DSLEEF_BUILD_INLINE_HEADERS=OFF',
2531
'-DCMAKE_POSITION_INDEPENDENT_CODE=ON',
2632
'-DCMAKE_INSTALL_PREFIX=' + meson.current_build_dir() / sleef_install_dir
27-
], check: false, capture: true)
33+
] + sleef_simd_flags, check: false, capture: true)
2834

2935
if sleef_configure.returncode() != 0
3036
error('SLEEF CMake configuration failed: ' + sleef_configure.stderr())

0 commit comments

Comments
 (0)