NeurIPS 2026QuestionsPapersAreasAboutMarkdown

Accelerating Long-Context LLM Prefill via Layer-wise Progressive Token Pruning in Local Deployment

Zhongxiang Wei, Zhaohan Wang, Zhixiong Zhang, Jin Zhao, Xiaoming Fu

NeurIPS page · OpenReview · Open on the map

Category: Efficient LLM Inference & Training › Sparse Long-Context Attention · Type: new method · Keywords: layer-wise token pruning, LLM prefill acceleration, local deployment, sparse attention, latency optimization

Areas: Long Context › Long-context mechanisms › Long-context attention mechanisms

Summary

FastPrefill is a recovery-free layer-wise token pruning system that determines optimal pruning schedules to accelerate LLM prefill while preserving quality, achieving up to 2.13× TTFT speedup.

Explained to a 5-year-old

When a big computer program reads a long text, it takes a long time to start giving answers. Some tricks only make part of the work faster, but they can make the answers less correct. The new idea looks at each layer of the program and decides which words to ignore, so it does less work. It does this planning ahead of time, and then during use each part of the program pays attention only to the words it needs. This makes the program answer faster while still giving good answers, especially on local devices where privacy matters.

Explained to a 5-year-old, longer

When you use a big language model on your own computer, it needs to read a long piece of text before it can answer. Reading that text is called the "prefill" stage, and it often takes the longest time. Existing tricks try to speed it up, but many only make part of the work faster or make the answers less accurate. The new idea looks at each layer of the model and decides which words can be skipped. It does this planning before the model runs, using a special optimizer that tries to keep the answers good. During actual use, each part of the model only pays attention to the words it needs, not all of them. This way, both the attention part and the feed-forward part of the model do less work. Because less work is done, the model starts answering much faster. The speed-up is up to more than twice as fast for the first token and over three times faster overall. The quality of the answers stays about the same as before. This helps when you need the model on a personal device where you can’t send data to the cloud. It makes powerful language models easier and safer to use in everyday situations.

For a technical reader

FastPrefill introduces a recovery-free, layer-wise token pruning scheme that determines optimal pruning schedules offline to meet latency constraints. It implements these schedules with an algorithm-system co-design that enables head-specific sparse attention, allowing each attention head to attend only to a dynamically selected subset of keys and values. By pruning tokens at both the attention and feed-forward network layers, the approach reduces overall compute and memory usage during the prefill phase. Evaluations on LongBench and RULER show that FastPrefill retains model quality while delivering up to 2.13× faster TTFT and 3.03× end-to-end speedup over existing baselines. This makes long-context LLM inference more practical for privacy-sensitive local deployments where resources are limited.

Problem

Accelerating long-context LLM inference on local devices is challenging because the prefill stage dominates latency, and existing methods either only speed up attention or compromise quality under memory constraints. There is a need for a method that reduces both attention and FFN computation without adding decoding overhead.

Method

The approach uses an offline data-driven optimizer to compute layer-wise token pruning schedules that maximize fidelity under a latency budget, and implements these schedules via algorithm-system co-design that enables head-specific sparse attention at runtime, where each head attends to its own selected key/value tokens.

Results

The approach maintains comparable inference quality while achieving up to 2.13× TTFT speedup and 3.03× end-to-end speedup over state-of-the-art baselines.

Contributions

A recovery-free layer-wise token pruning system that determines optimal pruning schedules without token recovery, and an algorithm-system co-design for head-specific sparse attention that reduces both attention and FFN computation under latency constraints.

Practical relevance

It enables faster, privacy-preserving long-context LLM inference on local devices, making advanced models more practical for sensitive applications.

Research questions this paper is counted under

This page was written by language models from the title and abstract of each paper, and the answers were checked by two other models. It can be wrong: check the paper itself. Suggest a correction