The SIMD backend contains explicit AVX/NEON dense matrix kernels and fallback paths for platforms without those instruction sets.
Public Entry Point
void matmul(const Matrix &A, const Matrix &B, Matrix &C, Backend b=default_backend)
C = A * B.
The dispatch path is:
num::matmul
-> num::backends::opt::matmul
Implementation Location
src/core/backends/opt/matrix.cpp
src/core/backends/simd/impl.hpp
The optimized backend is private to the library. Users select it with the Backend enum rather than including implementation headers.
Kernel Role
The SIMD path is the custom dense-kernel counterpart to BLAS:
Use it for:
- benchmarking the custom kernel against BLAS,
- validating the blocked/register-blocked implementations,
- running without an external BLAS.
FFT SIMD Backend
The spectral module has independent FFT backends:
void fft(const CVector &in, CVector &out, FFTBackend b=default_fft_backend)
Those are separate from the dense matrix Backend::simd path.
Benchmark
./build/benchmarks/numerics_bench --benchmark_filter="BM_Matmul|BM_FFT"