arXiv Science⌕ Search

arXiv · 2611.39931

SparseWafer: Fast Dynamic Sparse Prefill on a Wafer-Scale Accelerator

Abstract

Dynamic block-sparse attention skips most of the attention work of a long prompt. On accelerators whose multicast is statically routed and flow-controlled, such as wafer-scale engines, the pruning gains far less than the skipped work suggests: with the conventional placement, sparse attention that skips most of the blocks still takes most of the dense attention time. The cause is multicast backpressure: a route advances only when every destination has a free buffer, so processing elements (PEs) that receive the same key-value stream stall each other when their work falls at different points of it. We present SparseWafer, which reduces this stall by placing query rows. The rows that share one selection decision select the same key blocks, so spreading them cyclically over the PEs of a stream gives every PE the same work on every block, and we prove that such PEs run as fast as one PE alone, for any buffer depth. A per-head start offset, which starts each query head at a different set of PEs, extends this balance across the multicast routes that share one key-value stream; it depends only on tensor shapes and is fixed before run time. We evaluate SparseWafer on the Cerebras SDK's WSE-3 simulator and a model calibrated on it, with selection and data movement included. With the masks of a published selection method (XAttention), SparseWafer is 1.31-1.49x faster than sparse prefill with the conventional placement at each model's longest context. With these masks, sparse prefill loses at most 1.8 points of accuracy on the RULER long-context benchmark, and on the denser masks of RULER prompts SparseWafer is still 1.28-1.54x faster than dense prefill at 128K. It is also faster than mask-aware load balancers and within 5-10% in attention time of an idealized, zero-cost one: on such networks, the shape of the computation decides almost all of where each row belongs.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Jianchang Su, Yifan Zhang, Wei Zhang. 2026-11-29. SparseWafer: Fast Dynamic Sparse Prefill on a Wafer-Scale Accelerator. https://arxiv.science/abs/2611.39931

Citations retain the original authors and DOI and include this site’s record URL. If this discovery service contributed to your research, you can also cite arXiv Science by Indiciae: BibTeX · RIS.

KEEP EXPLORING

Related papers

ChipArc: Auditable Multi-Agent RTL Generation, Repair and Optimization with Verifier-Gated Memory

Register-transfer level (RTL) code must be both functionally correct and physically efficient in timing, area, and energy, yet LLM-based RTL agents draft plausible designs without being able to certify correctness or reliably guide repair. We present ChipArc, an auditable multi-agent framework in which models propose RTL and diagnose failures while a deterministic controller verifies each candidate and promotes only strictly verified improvements, recording every decision for offline audit. A key design choice is a single verifier-gated global memory shared across concurrent agents: each stores a bounded record of an evaluated repair (hypothesis, change, and verifier-measured outcome), so agents reuse one another's verified experiences across tasks, while excluding current-task and hidden assets (e.g., golden references). Using Kimi K3, ChipArc solves 89 of 92 tasks in CVDP's non-commercial agentic code-generation subset at the lowest mean model cost per pass among the evaluated systems. On the 43 verifier-valid ChipBench Verilog-generation tasks, it solves a mean of 38 tasks, compared with 34 for ACE-RTL and 27 for MAGE. A controlled ablation shows the shared memory raises repair coverage by about 12%. Finally, we carry the same verifier-controlled discipline all the way to physical optimization of a GCD/RSA accelerator, reporting reductions in area, delay, and energy; a bounded formal gate also exposes a protocol bug that both the functional harness and a separate 24-test regression miss.

cs.AR↗

svlang-sdk: A Zero-Dependency Multi-Domain Compiler SDK for Modular VLSI Frontend Verification and EDA

VLSI frontend flows parse the same chip five times across SystemVerilog, UPF, SDC, SystemRDL/IP-XACT, and SystemC. Disconnected tools maintain separate elaboration graphs, cache stale state, and expose unstable C++ ABIs or text dumps, forcing brittle glue scripts while IDEs and AI agents stall on full-chip re-elaboration and megabyte JSON payloads. We present svlang-sdk, a 73,892-line zero-dependency C++23 (-fno-exceptions -fno-rtti) hardware compiler spine and frozen C11 SDK (libsvlang_sdk_c). Five acyclic layers separate: (0) a Salsa-style incremental query host (AnalysisHost/AnalysisSnapshot) with durability tiers, early cutoff, cooperative cancellation, and epoch-scoped arenas; (1) five pluggable frontends (SV, UPF 3.1, SystemC 3.0, SDC, RDL/IP-XACT) bound onto one dense EntityId graph with OpenUSD-style overlays and ExplainValueSource provenance; (2) a word-level SSA RTL netlist, immutable .svdb snapshots, Hydra-style merging views, and macro-aware AtomicChange refactoring; (3) a dual-plane ABI pairing 39 C11 symbols (zero leaked C++ _Z* symbols) with the header-only Apache Arrow C Data Interface and C++23, Python, Rust, and TypeScript bindings; and (4) LSP 3.17, MCP 2026-07-28, DAP v1.71, and Surfer WCP servers. Linking svlang-sdk deleted 16,351 duplicated frontend lines from our 88,254-line sv++ simulator, drives 436 lint rules in svlang-lint, and isolates a 42,472-line consolidation seam in our 159,225-line Rust formal verifier InFormal. On arm64 macOS, all 14 C++23 test suites pass under Debug, ASan+UBSan, TSan, and Release; comment edits hit early cutoff in 10 us with flat RSS across 1,000 epochs; Arrow exports 53,005 entities in 0.9 ms (37.3x faster than JSON); and four polyglot small-tool proofs each fit under 150 lines.

cs.AR↗

HARP: Rethinking ATPG-Augmented On-Chip Random Patterns to Enhance Test Efficiency

Increasing design complexity, coupled with the emerging trend of chiplet-based heterogeneous 3D integration, necessitates substantial improvements in test efficiency in terms of the number of ATPG patterns and/or test cycles. While test cost has been a major driver behind this, 3D integration with high I/O density may also benefit from reduced external pattern application. In this paper, we present \STAR, a hybrid test generation framework that addresses the above issue by using ATPG-augmented on-chip random patterns to achieve a significant reduction in ATPG pattern count as well as overall test cycles at equivalent fault coverage compared to the same hybrid flow with fully pseudo-random patterns. Each pattern takes its primary-input bits from ATPG and its state bits from an on-chip pseudo-random number generator (PRNG), and is applied without a per-pattern scan load or unload. We show that the insertion of appropriate Design-for-Test (DFT) logic, e.g., test points, can further enhance test efficiency. We specifically note that DFT-enabled ATPG-augmented random patterns alone can provide considerably high structural coverage (avg. $\sim$89\%), leaving a small subset of random-resistant faults to be covered by structural ATPG. We have implemented \STAR~as a standalone tool integrated into a commercial test automation tool flow. Experimental analysis on open-source benchmarks, including four AI accelerators, shows promising results with 33\% improvement on average in ATPG test patterns and an average of 27\% reduction in test cycles.

cs.AR↗