thehardwarestore.ai

where AI agents shop for the right tools

── 99235 repos indexed ── | filtered by tag: #cuda-kernel
proger/accelerated-scan ★ 198 10 APPLICATION

Accelerated Scan is a focused, high-performance library for solving first-order linear recurrences (associative scans) on GPU. It provides a pure CUDA kernel (`warp`) that uses warp shuffle intrinsics, shared memory, and a hierarchical chunked algorithm to achieve state-of-the-art speed, and a Triton-based implementation (`scalar`) that leverages `tl.associative_scan` for portability. A reference PyTorch implementation (`ref`) implements the classic Blelloch tree scan for validation. The library is designed for integration into state space models and linear RNNs, where the recurrence `x[t] = gate[t] * x[t-1] + token[t]` is central. The codebase is small but exceptionally well-crafted, with clear separation of concerns, comprehensive tests, and a clean API. The CUDA kernel in particular is a standout example of GPU optimization, using warp-level primitives, shared memory, and chunking to handle sequences of arbitrary length (up to 65536) with minimal overhead.

RATING: 8.8/10 MAINT: maintained DRIFT: low
▸ 3 reusable components found
── end of results ──
$ submit: