Skip to content

WASM SIMD view-tag scanner #184

Description

@truthixify

Tier: L (5-7 days) | Type: perf

Context. WebGPU (Wave 7 #1) targets browser GPU. Node servers and older browsers get no benefit. A WASM SIMD implementation of the view-tag inner loop runs everywhere Node and modern browsers ship, and closes the gap between the CPU-JS baseline (already 229x from view-tag batching) and the GPU path. Complementary to WebGPU, not competing.

Scope.

  • Rust or AssemblyScript inner loop under src/chains/stellar/scanner/wasm/ compiled to .wasm with SIMD128 features.
  • JS wrapper feature-detects WebAssembly.SIMD and falls back to the pure-JS batch path.
  • Public API unchanged (fetchAnnouncementsStream).
  • Bench in test/chains/stellar/bench/scan.bench.ts adds a WASM row.

Acceptance.

  • Bench shows >= 2x speedup vs CPU-JS on 10k events in Node 20
  • Same speedup verified in a headless Chrome Playwright run
  • Fallback path taken (verified by test) when SIMD is unavailable
  • .wasm byte size <= 32 KB, checked in size-limit

Files. src/chains/stellar/scanner/wasm/ (new), src/chains/stellar/scanner/index.ts, src/chains/stellar/announcements.ts, test/chains/stellar/bench/scan.bench.ts, package.json.

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programdripsFunded via Drips Networkhelp wantedExtra attention is neededperfPerformance / optimizationstellarTouches Stellar / Soroban codestellar-waveAuto-created for Wave 8wave-8Auto-created for Wave 8

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions