98× Faster LLM Routing Without a Dedicated GPU: Flash Attention, Prompt Compression, and Near-Streaming for the vLLM Semantic Router
On the map: Efficient LLM inference and serving → Serving systems and request scheduling
Abstract (arXiv)
System-level routers that intercept LLM requests for safety classification, domain routing, and PII detection must be both fast and operationally lightweight: they should add minimal latency to every request, yet not require a dedicated GPU -- an expensive resource better used for LLM inference itself. When the router co-locates on the same GPU as vLLM serving instances, standard attention's O(n2) memory makes long-context classification (8K--32K tokens) impossible: at 8K tokens, three concurrent classifiers need ~4.5,GB for attention masks alone, far exceeding the memory left by vLLM. We present three staged optimizations for the vLLM Semantic Router, benchmarked on AMD Instinct MI300X, that solve both the latency and the memory problem. Stage~1: a custom CK Flash Attention operator for ONNX Runtime on ROCm reduces attention memory from O(n2) to O(n) and end-to-end (E2E) latency from 4,918,ms to 127,ms (38.7×), enabling 8K--32K tokens where SDPA OOMs. Stage~2: classical NLP prompt compression (TextRank, position weighting, TF-IDF, and novelty scoring) reduces all inputs to ~512 tokens without neural inference, capping both latency and GPU memory at a constant regardless of original prompt length (E2E 127→62,ms, 2.0×). Stage~3: near-streaming body processing with adaptive chunking and zero-copy JSON eliminates serialization overhead (E2E 62→50,ms, 1.2×). Cumulatively: 98× improvement (4,918,ms to 50,ms), 16K-token routing in 108,ms, and a total router GPU footprint under 800,MB -- small enough to share a GPU with LLM serving and removing the need for a dedicated accelerator. Stage~1 targets AMD ROCm (NVIDIA GPUs already have FlashAttention via cuDNN); Stages~2 and~3 are hardware-agnostic.
Key facts. Cited by 2 papers in the map (data through 14 Oct 2026). Placed in Serving systems and request scheduling, one of 12 directions in Efficient LLM inference and serving. Builds on 14 of its 32 references that are in the map. First posted on arXiv 13 Mar 2026.
Builds on
14 of 32 references.
Closest ancestors · 1
Same direction, newest first
Other references · 13
- 2023Efficient Memory Management for Large Language Model Serving with PagedAttentioncited by 5,944
- 2022FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awarenesscited by 3,673
- 2023Lost in the Middle: How Language Models Use Long Contextscited by 3,455
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,186
- 2024RouteLLM: Learning to Route LLMs with Preference Datacited by 682
- 2023YaRN: Efficient Context Window Extension of Large Language Modelscited by 601
- 2024Smarter, Better, Faster, Longer: A Modern Bidirectional Encoder for Fast, Memory Efficient, and Long Context Finetuning and Inferencecited by 554
- 2024LLMLingua-2: Data Distillation for Efficient and Faithful Task-Agnostic Prompt Compressioncited by 348
- 2023Compressing Context to Enhance Inference Efficiency of Large Language Modelscited by 189
- 2023Discrete Prompt Compression with Reinforcement Learningcited by 42
- 2025Understanding and Improving Information Preservation in Prompt Compression for LLMscited by 15
- 2026R2-Router: A New Paradigm for LLM Routing with Reasoningcited by 14
Built on by
Citing papers per year: 2026: 2.
2 papers.
Similar, not cited
Close in wording, no citation either way
- 2026LLM Router: Rethinking Routing with Prefill Activations
- 2026Do Dynamic Routers Need Memory? HeRo: History-Aware Routing for Efficient LLM Inference
- 2026RequestRouter: Request-Boundary Routing for Efficient Single-GPU LLM Inference
- 2026Lodestar: An Online-Learning LLM Inference Router
- 2026Calibrate, Then Route: A Measured Study of Learned Request Routing for Disaggregated LLM Serving
- 2025RAPID-LLM: Resilience-Aware Performance analysis of Infrastructure for Distributed LLM Training and Inference ↗
- 2026Flux Attention: Context-Aware Hybrid Attention for Efficient LLMs Inference
- 2024Performance Characterization of Expert Router for Scalable LLM Inference