Expand description
Runtime-dispatched SIMD abstractions and dynamic facade. Runtime-dispatched SIMD operations.
§Monomorphization chain
sum::<f32>(data) -> f32::sum(data) -> sum::dispatch_sum::<f32>(data) -> avx2 kernel.
Modules§
- argmax
- Generic runtime-dispatch argmax kernel.
- argmin
- Generic runtime-dispatch argmin kernel.
- binary
- Generic runtime-dispatch elementwise binary kernel.
- complex
- Generic interleaved complex kernels.
- dot
- Generic runtime-dispatch dot product kernel.
- gemm
- Generic runtime-dispatch tiled GEMM kernel.
- gemv
- Generic runtime-dispatch register-blocked matrix–vector product (
y += A · x). - gemv_
strided - Generic runtime-dispatch register-blocked sub-matrix GEMV (
y += A · x, row stridelda). - gemv_
transpose - Generic runtime-dispatch transposed matrix–vector product (
y += Aᵀ · x). - gemv_
transpose_ strided - Generic runtime-dispatch transposed sub-matrix GEMV (
y += Aᵀ · x, row stridelda). - masked
- Runtime-dispatched masked SIMD operations.
- max
- Generic runtime-dispatch max-reduction kernel.
- min
- Generic runtime-dispatch min-reduction kernel.
- modular
- Modular-arithmetic kernels for transform workloads.
- scale
- Generic runtime-dispatch in-place scale kernel.
- sparse
- Runtime-dispatched sparse matrix-vector multiplication.
- sum
- Generic runtime-dispatch sum kernel.
Traits§
- SimdOps
- Sealed extension trait implementing dynamic runtime SIMD dispatch for any
T: Scalar.
Functions§
- abs_max
- Reduces the slice to
max |x|(∞-norm accumulator);T::ZEROfor empty. - abs_sum
- Reduces the slice to
Σ |x|(L1-norm accumulator);T::ZEROfor empty. - argmax
- Returns the first maximum, or
Nonefor empty or NaN-containing data. - argmin
- Returns the first minimum, or
Nonefor empty or NaN-containing data. - axpy
- Fused row update
out[i] += alpha * x[i](AXPY) via runtime-dispatched SIMD with no temporary allocation. Errors on length mismatch. - axpy_
rows - Fused multi-row update
out[row, i] += alphas[row] * x[i]via one runtime-dispatched SIMD kernel.outis a row-major strided window. - axpy_
rows_ batch - Fused batched multi-row update:
out[row, i] += sum_k alphas[k, row] * x_panel[k, i]via one runtime-dispatched SIMD kernel.alphasis depth-major withrowselements per depth,x_panelis depth-major withcolselements per depth, andoutis a row-major strided window. - dispatch_
reduce_ popcount - dispatch_
reduce_ popcount_ and - dispatch_
reduce_ popcount_ or - dispatch_
reduce_ popcount_ xor - dot
- Computes the dot product of two slices using runtime-dispatched SIMD.
- elementwise_
add - Computes the elementwise sum of two slices and writes to
out. - elementwise_
div - Computes the elementwise quotient of two slices and writes to
out. - elementwise_
mul - Computes the elementwise multiplication of two slices and writes to
out. - elementwise_
sub - Computes the elementwise difference of two slices and writes to
out. - gemv
- Computes register-blocked GEMV
y += A · xwith runtime backend selection. - gemv_
strided - Computes register-blocked sub-matrix GEMV
y += A · xwith row stridelda, runtime backend selection.Ais a row-majornrows × ncolsblock with leading dimensionlda ≥ ncols;lda = ncolsis the packedgemv(). Accumulates intoy. - gemv_
transpose - Computes register-blocked transposed GEMV
y += Aᵀ · xwith runtime backend selection — the complement ofgemv(). - gemv_
transpose_ strided - Computes register-blocked transposed sub-matrix GEMV
y += Aᵀ · xwith row stridelda, runtime backend selection.lda = ncolsis the packedgemv_transpose(). Accumulates intoy. - interleaved_
complex_ dot - Computes an interleaved complex dot product using a monomorphized SIMD architecture.
- interleaved_
complex_ dot_ runtime - Computes an interleaved complex dot product using Hermes runtime provider selection.
- interleaved_
complex_ mul_ assign - Multiplies interleaved complex values in-place using a monomorphized SIMD architecture.
- interleaved_
complex_ mul_ assign_ runtime - Multiplies interleaved complex values in-place using Hermes runtime provider selection.
- masked_
add - Computes the elementwise sum of elements matching a boolean mask.
- masked_
dot - Computes the dot product of elements matching a boolean mask.
- masked_
sum - Computes the sum of elements matching a boolean mask.
- max
- Computes the maximum element of the slice using runtime-dispatched SIMD.
- min
- Computes the minimum element of the slice using runtime-dispatched SIMD.
- ntt_
butterfly_ stage_ u64 - Executes one exact modular radix-2 NTT butterfly stage over
u64residues. - reduce_
popcount - Computes the horizontal sum of population counts of all elements using runtime-dispatched SIMD.
- reduce_
popcount_ and - Computes the horizontal sum of population counts of
a[i] & b[i]using runtime-dispatched SIMD. - reduce_
popcount_ or - Computes the horizontal sum of population counts of
a[i] | b[i]using runtime-dispatched SIMD. - reduce_
popcount_ xor - Computes the horizontal sum of population counts of
a[i] ^ b[i](Hamming distance) using runtime-dispatched SIMD. - scale
- Multiplies every element of
databyscalarin-place. - spmv_
bcoo - Computes sparse SpMV using const-generic Blocked-COO tiles.
- spmv_
csr - Computes sparse SpMV using CSR:
y += A · x. - spmv_
dense_ masked - Computes sparse SpMV using Dense-with-Mask.
- spmv_
sellp - Computes sparse SpMV using const-generic Sliced ELLPACK (SELL-p).
- sum
- Computes the sum of elements in the slice using runtime-dispatched SIMD.
- tiled_
gemm - Computes register-blocked tiled GEMM:
c += A * B.