Expand description
Portable SIMD primitives + canonical block-rate audio ops.
Two backends, feature-gated:
wide-backend(default): stable Rust, uses thewidecrate. Mapsf32x4/f32x8/f64x2/f64x4onto SSE2 / AVX2 on x86, NEON onAArch64, scalar fallback elsewhere.- (planned)
portable-simd-backend: nightly-only, swaps incore::simdwhen it stabilizes. Same public type aliases.
Consumers never name the backend - they import
truce_simd::ops (f32) / truce_simd::ops64 (f64) and the
correct intrinsics get wired in automatically.
All ops here are pure math. No atomics, no parameter reads, no
audio-thread allocation. They’re meant to be the inner-loop
complement to a truce_params::FloatParam::read_block::<N>() /
truce_core::AudioBuffer::chunks_mut::<N>() driver in
process().
Modules§
- math
- Vectorized transcendentals at audio-grade precision.
- ops
- Block-rate audio ops at
f32. Seecrate::ops64for thef64mirror. - ops64
- Block-rate audio ops at
f64. Mirror ofcrate::ops(f32); see that module for the per-op contracts. The wider lane width meansf64x4SIMD lanes for the samewidebackend; chunk granularity is 4 instead of 8. - simd
- Lane-width aliases. Stable across backends so consumers don’t
have to rewrite types when we flip the default to
portable-simd-backend.