
SimdIntrinsicsVectorOps
- Namespace
- Rowles.LeanLucene.Search.Simd
- Assembly
- Rowles.LeanLucene.dll
Explicit-intrinsics SIMD path for vector arithmetic. Selects the widest available instruction set at runtime: AVX-512 → AVX2 → SSE → scalar. Provided alongside SimdVectorOps for benchmark comparison; the slower of the two will be removed once measurements are concluded.
public static class SimdIntrinsicsVectorOps
SimdIntrinsicsVectorOps
IsAvx2Supported
True when the running hardware supports AVX2 (256-bit float path with FMA).
IsAvx512Supported
True when the running hardware supports AVX-512F (single-precision FMA path).
IsSseSupported
True when the running hardware supports SSE (128-bit float path).
CosineSimilarity(ReadOnlySpan<float>, ReadOnlySpan<float>)
Cosine similarity between two equal-length vectors, using explicit intrinsics.
DotProduct(ReadOnlySpan<float>, ReadOnlySpan<float>)
Dot product using explicit intrinsics.