Expand description
WASM/SIMD integration for browser-based inference (spec §L) WASM/SIMD Integration Module
Provides WebAssembly support for browser-based inference with SIMD acceleration.
§QA Verification (Section L: 15 points)
- L1: wasm32-unknown-unknown target compiles
- L2: SIMD128 feature enabled in WASM
- L3: WASM module size <5MB (without model)
- L4: WASM loads in <500ms (tested in browser)
- L5: Memory.grow() works for model loading
- L6-L15: See tests below
§References
- WebAssembly SIMD Spec: https://github.com/WebAssembly/simd
- wasm-bindgen: https://rustwasm.github.io/wasm-bindgen/
Structs§
- Simd
Verification - SIMD operation results for verification
- Wasm
Inference Session - WASM inference session for streaming token generation
- Wasm
Memory Config - WASM memory configuration for model loading
- Wasm
Tensor View - Zero-copy view into WASM linear memory
Functions§
- dot_
simd_ friendly - Dot product using SIMD-friendly accumulation
- matmul_
simd_ friendly - Matrix multiplication using SIMD-friendly layout
- verify_
f32x4_ operations - Verify SIMD f32x4 operations produce correct results
- verify_
i32x4_ operations - Verify SIMD i32x4 operations produce correct results