[Bug]: SIGILL / Illegal instruction on `import zvec` in Ubuntu 24 (Proxmox/KVM VM), also reproduces on Fedora (x86_64)
Description
Reproducible SIGILL / Illegal instruction on import (import zvec) in Linux x86_64 VM (Proxmox/KVM)
I can reproduce an Illegal instruction (core dumped) crash during import, before any query/print.
What happened
zvec installs successfully with pip, but importing it immediately crashes with:
Illegal instruction (core dumped)
### Steps to Reproduce
```python
1. Create a fresh Python environment (tested with both `venv` and `conda`)
2. Install Zvec:
python -m pip install "zvec==0.1.1"
python -m pip install "zvec==0.2.0"
python -c "import zvec; print('OK import zvec')"
Illegal instruction (core dumped)
Logs / Stack Trace
Operating System
Ubuntu 24.04 (Proxmox/KVM VM) x86_64; also reproduced on Fedora x86_64
Build & Runtime Environment
Python 3.11 (conda) and Python 3.12 (venv); zvec 0.1.1 and 0.2.0 (pip wheels, manylinux x86_64); Proxmox/KVM VM on x86_64 host; CPU has AVX2 but no AVX512BW
Additional Context
- [ ] I've checked
git status— no uncommitted submodule changes - [ ] I built with
CMAKE_BUILD_TYPE=Debug - [ ] This occurs with or without
COVERAGE=ON - [ ] The issue involves Python ↔ C++ integration (pybind11)
Same on Ubuntu 24.04.1 LTS, Linux 6.6..87.2-microsoft-standard-WSL2, x86-64. Same outcome.
me too. even the official binary from pypi has the same problem.
workaround proposed here,
change AUTO_DETECT_ARCH ON to AUTO_DETECT_ARCH OFF in cmake/option.cmake, and the built binary will work.
me too. even the official binary from
pypihas the same problem.workaround proposed here,
change
AUTO_DETECT_ARCH ONtoAUTO_DETECT_ARCH OFFincmake/option.cmake, and the built binary will work.
Thanks,it works for me
Thank you all for your reports and discussions. We've provided a viable workaround in issue #185 and will use that issue to track the implementation of a more robust solution. We'll close this issue for now.