Skip to content

ci: add diagnose_numpy.py; fix YAML syntax #77

ci: add diagnose_numpy.py; fix YAML syntax

ci: add diagnose_numpy.py; fix YAML syntax #77

Workflow file for this run

# Bit-exact CI: every push/PR must pass all 792 IEEE-754 tests.
#
# Requirements driving the setup:
# - numpy must be pip-installed (its bundled OpenBLAS exposes sdot_64_ /
# cblas_sgemm64_ / __svml_exp8 etc. that numpycpp resolves via dlsym)
# - AVX-512 hardware is required at runtime (-mavx512f compile flag +
# __attribute__((target)) guards; GitHub ubuntu-latest uses Intel Xeon
# which supports AVX-512)
# - pybind11, Eigen3, OpenMP needed to build the test extension module
name: CI
on:
push:
branches: [ master, bit-exact ]
pull_request:
branches: [ master ]
jobs:
test:
name: bit-exact tests — Python ${{ matrix.python }} / ${{ matrix.compiler }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- python: "3.10"
compiler: g++
- python: "3.11"
compiler: g++
- python: "3.12"
compiler: g++
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
- name: Install Python dependencies
run: pip install "numpy>=1.23,<2.0" pybind11 pytest cmake
- name: Install system dependencies
run: |
sudo apt-get update -qq
sudo apt-get install -y libeigen3-dev
# libgomp1 (OpenMP runtime) and omp.h (OpenMP headers) are bundled
# with GCC on Ubuntu 24.04 — no separate libgomp1-dev package exists
- name: Diagnose numpy symbols
run: |
python diagnose_numpy.py
grep -q avx512f /proc/cpuinfo && echo "AVX-512: present in cpuinfo" || echo "AVX-512: NOT in cpuinfo"
working-directory: tests
- name: Configure
run: cmake -S tests -B tests/build -DCMAKE_BUILD_TYPE=Release
env:
CXX: ${{ matrix.compiler }}
- name: Build
run: cmake --build tests/build -j$(nproc)
- name: Run bit-exact tests
run: |
cd tests
python -m pytest test_all.py -q --tb=short --no-header