C++ · Highlights

Highlights

8.0.0-rc.1 · b1f866ab

This is the primary SDK in the project. It is the right layer if you want exact control over dtypes, allocators, packed buffers, dispatch, and host-side partitioning.

Full kernel surface. All public operation families are reachable from native code. No hidden threading. NumKong does not own a thread pool. No hidden allocation. C APIs take caller-owned buffers, and C++ wrappers make ownership explicit. Mixed precision by default. Small storage types widen into safer accumulator and output types. Allocator-aware containers. vector, tensor, packed_matrix, and packed_maxsim accept custom allocators. Unaligned inputs are fine. Packing handles internal layout itself and does not require caller-side alignment.

§ Ecosystem Comparison

FeatureNumKongOpenBLASEigen
Operation familiesdots, distances, binary, probability, geospatial, curved, shapes, sparse, MaxSim, elementwise, reductions, cast, trigdense linear algebra onlydense LA, some reductions and elementwise
PrecisionSub-byte to Float64 dtypes; automatic widening per scalar type; Kahan-compensated summation; 0 ULP Float32/Float64 where applicableFloat32, Float64 only; same-type in/out; no compensated summationFloat16/BFloat16 partial; no Float8 or sub-byte; manual casts; no compensated summation
Runtime SIMD dispatchper call, by capability mask, across x86, Arm, RISC-V, and GPUsload-time CPU detection; one kernel set per processcompile-time ISA flags only
Packed matrix, GEMM-likepacked_matrix — pack once, reuse across query batchesinternal opaque packing per GEMM call; no persistent packed formno equivalent packed reuse abstraction
Symmetric kernels, SYRK-likeskips duplicate pairs, up to 2x speedup for self-distanceSSYRK/DSYRK for rank-k updates.selfadjointView for rank-k updates
Memory modelCaller-owned buffers; C++ adds tensor<T,A> with per-container allocatorsCaller-managed buffers; no container abstractionLazy expression templates avoid most temporaries; aligned_allocator provided