- Rating
- 4
- Clarity
- 3
- Confidence
- 4
- Originality
- 3
- Quality
- 2
- Significance
- 3
Read review
Summary
This paper investigates the acceleration of the prefill stage in long-context Large Language Models (LLMs) tailored for local, single-GPU deployments, where the Time-to-First-Token (TTFT) is heavily dominated by prompt processing. The proposed method, FastPrefill, couples an offline data-driven optimizer (which searches for layer-wise token pruning schedules under explicit latency constraints) with an online execution pipeline. The online runtime recomputes lightweight attention scores, performs head-specific KV token selection, and executes a customized boundary-aware sparse attention kernel. Evaluated on LongBench and RULER, the paper reports that FastPrefill achieves notable speedups in both TTFT and end-to-end latency while maintaining competitive generation quality. The performance margins are particularly pronounced when compared against attention-only or recovery-based pruning baselines.
Strengths and weaknesses
Strengths
- Solid Algorithm-System Co-Design: Unlike purely heuristic pruning methods, this work successfully translates abstract layer-wise compression schedules into executable, hardware-efficient sparse attention, elegantly splitting offline schedule optimization from online execution.
- Clever Boundary-Aware Kernel: The introduction of a binary search mechanism to dynamically compute causal visibility boundaries in the custom Triton kernel is highly innovative. This design allows non-contiguous, head-specific KV tokens to be physically compacted while guaranteeing mathematical correctness during causal attention scanning.
- Targeted Ablation Studies: Although concise, the ablation experiments in Section 4.6 effectively validate the system’s core claims. Figure 10 successfully quantifies the necessity of the offline optimizer and the head-specific selection mechanism rather than merely tuning hyper-parameters.
Weaknesses & Questions
- In Section 3.1.2, the authors directly adopt CMA-ES to optimize the surrogate objective. Why was CMA-ES specifically chosen over other black-box or derivative-free optimization techniques? Comparative analysis or mathematical intuition should be provided to justify this design choice.
- Regarding the calibration data, although the authors utilized a split of LongBench samples excluded from the final evaluation for offline profiling, these samples still share an identical data distribution with the evaluation set. How does FastPrefill generalize when calibrated on a completely different domain or an out-of-distribution (OOD) dataset? A deeper analysis of potential data distribution shift is needed.
- In Section 3.2.3, the paper introduces a polynomial model to predict path latency. However, it remains unclear whether this fitting process is performed concurrently with the offline schedule search or treated as a separate standalone profiling step. Could the authors clarify the exact workflow, computational overhead, and data collection details for this fitting component?
- In Section 4.1, the authors state that SpecPrefill and PyramidInfer were not evaluated on the Qwen series due to a lack of official support. However, the core architecture of Qwen2.5 is remarkably similar to Llama3 (both utilizing standard GQA, RoPE, and similar MLP dimensions), making them highly interchangeable in modern open-source backends. Please justify why these baselines could not be adapted to Qwen2.5, as omitting them weakens the thoroughness and fairness of the evaluation on the Qwen model.
Questions
Please refer to the specific bullet points listed in the "Weaknesses" section above.
Limitations
yes
Paper formatting concerns
No major formatting issues found in this paper.
Final justification
The rebuttal resolves most of my original concerns, particularly regarding the choice of CMA-ES, the latency profiling workflow, OOD calibration robustness, and the missing SpecPrefill results on Qwen2.5. Given these satisfactory responses, I am happy to raise my score.
Thank you for your detailed review and valuable feedback.
Q1: Why was CMA-ES specifically chosen over other black-box or derivative-free optimization techniques?
We clarify that CMA-ES is one of several possible derivative-free optimizers. We selected it by jointly considering search efficiency and the structure of our formalized schedule-search problem.
(1) Population-based methods, such as differential evolution, genetic algorithms, particle swarm optimization, and CMA-ES, are natural for our problem because they support global exploration and parallel candidate evaluation. Among them, CMA-ES additionally adapts the covariance of its sampling distribution, allowing it to capture correlations among pruning decisions at different layers. Its population can also be evaluated directly with our optimized batched GPU implementation described in Appendix E.
(2) Exhaustive and non-adaptive methods are poorly matched to the dimensionality of our search space. Grid search suffers from combinatorial growth: for a 32-layer model, even discretizing each layer-wise pruning variable into only three candidate values produces 332≈1.85×1015 schedules, which is infeasible to evaluate. Random and quasi-random search do not use feedback from previous evaluations. Even after finding a region containing good solutions, they do not allocate more samples to that region. When only a limited number of candidate schedules can be evaluated, this makes them inefficient in a high-dimensional search space.
(3) Direct-search methods such as coordinate search, pattern search, Nelder–Mead, and Powell’s method can optimize non-differentiable objectives, but they do not explicitly learn the full cross-variable covariance structure. This is less suitable for our strongly coupled layer-wise schedule, where beneficial updates may require coordinated changes across multiple layers.
(4) Standard Gaussian-process Bayesian optimization becomes difficult in our multi-dimensional (28 for Qwen and 32 for Llama) search space and typically requires sequential surrogate updates. Moreover, the discrete changes induced by cascaded top-k selection reduce the effectiveness of conventional smooth kernels.
(5) Zeroth-order methods such as finite differences and SPSA estimate gradients from small changes in the pruning ratios. However, because top-k selection is discrete, a small change may either have no effect or suddenly change the selected tokens. This makes the estimated gradients unreliable.
Q2: How does FastPrefill generalize when calibrated on a completely different domain or an out-of-distribution (OOD) dataset?
To directly examine calibration-distribution sensitivity, we additionally optimize three independent schedules using out-of-distribution calibration data from L-Eval [1], BookSum [2], and Tau2 [3]. Compared with LongBench, L-Eval is an independent long-context benchmark with different document sources and task compositions; BookSum focuses on long-form narrative summarization; and Tau2 contains agentic prompts composed of domain policies, tool descriptions, and user scenarios.
The LongBench-calibrated schedule achieves an average LongBench score of 51.47, while the schedules calibrated on BookSum, Tau2, and L-Eval achieve 50.97, 50.78, and 50.35, respectively, corresponding to 97.8%–99.0% retention of the LongBench-calibrated performance. Performance on natural-language QA and summarization remains particularly stable, while larger variations are mainly concentrated in the synthetic and code categories.
These results demonstrate that the learned pruning schedules are relatively robust to changes in the calibration distribution, although some task-specific sensitivity remains. We hypothesize that this robustness arises because the optimized schedule mainly captures model-level layer redundancy, which is partially shared across domains.
[1] An, Chenxin, et al. “L-Eval: Instituting Standardized Evaluation for Long Context Language Models.” ACL 2024.
[2] Kryściński, W., et al. “BookSum: A Collection of Datasets for Long-Form Narrative Summarization.” Findings of EMNLP 2022.
[3] Barres, Victor, et al. "τ2-Bench: Evaluating Conversational Agents in a Dual-Control Environment." arXiv preprint arXiv:2506.07982 (2025).
Q3: Is the path-latency fitting performed concurrently with the offline schedule search or as a separate profiling step?
(1) Relationship with the CMA-ES schedule search. The path-latency fitting is a separate, one-time hardware profiling stage and is performed independently of the CMA-ES schedule search. CMA-ES uses the FLOPs-based surrogate G(R), while the fitted latency models are used only for runtime path selection. Therefore, fitting is independent of and adds no overhead to the CMA-ES search.
(2) Exact workflow and data collection details.
a) For each model, we evaluate sequence lengths n from 1,024 to 64,512 with a step of 2,048 and token-retention ratios r from 0.10 to 0.90 with a step of 0.05, resulting in 544 profiling configurations. For each configuration, we perform three warm-up iterations followed by ten timed iterations using CUDA events and record the mean latency.
b) The dense-path measurement includes the standard dense attention execution. The sparse-path measurement includes online score computation, retained-index construction, KV compaction, and boundary-aware sparse attention. Operations shared by both paths, such as the QKV/O projections and FFN, are excluded because they do not affect the path-selection decision.
c) Collecting the profiling data for dense path and sparse path takes approximately 16.2 and 13.3 minutes, respectively, for Llama3.1-8B, and 15.4 and 12.2 minutes, respectively, for Qwen2.5-7B. After data collection, we construct the polynomial feature matrices and fit the coefficients using ordinary least squares implemented with numpy.linalg.lstsq. The regression itself takes approximately 0.0004 s for sparse path and 0.0002 s for dense path on both models.
Q4: Justify the omission of baselines for Qwen2.5
Thanks for your advice. We adapt the feasible missing baseline, SpecPrefill, to Qwen2.5 and add both quality and efficiency results. Meanwhile, we omit PyramidInfer and DuoAttention on Qwen2.5. The reasons are as follows:
(1) PyramidInfer. Its main limitation is feasibility under our single-GPU setting. On an RTX 4090, PyramidInfer runs out of memory beyond a 4K input length with Qwen2.5-7B because its token-selection procedure incurs quadratic O(n2) memory overhead from attention-score materialization. Since it cannot run over the long-prompt lengths evaluated in our target scenario, including it would not provide a meaningful comparison.
(2) DuoAttention. DuoAttention requires a model-specific assignment of retrieval and streaming heads, so the pattern trained for Llama cannot be directly reused for Qwen2.5. In response to this feedback, we attempted to train a Qwen2.5-specific pattern using the official procedure, multiple random seeds, and the recommended configuration, but failed to obtain a converged pattern. Therefore, we could not construct a reliable DuoAttention baseline for Qwen2.5.
(3) SpecPrefill. We show the performance results and efficiency results below (draft model: Qwen2.5-1.5B), which are consistent with the observations on Llama3.1-8B. The efficiency experiment uses a 70% retention ratio because its average LongBench score is close to that of FastPrefill (50.15 vs. 50.25). The TTFT and end-to-end tables report the relative speedup normalized against the Origin baseline (1.00x); higher is better. End-to-end latency includes 32 generated tokens.
Longbench quality:
TTFT comparison (Relative Speedup):
E2E comparison (Relative Speedup):