A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 12, 14:45 UTC
[Attention] add `_cudagraph_support` for linear attention (#28934)
Signed-off-by: zjy0516 <riverclouds.zhu@qq.com>
Jiangyun Zhu committed
Nov 25, 2025 at 12:25 UTC
81db702ed28d9a6edbd59fbd0ec039e107d36bc0
1 file changed
+3
vllm/v1/attention/backends/linear_attn.py
+3
@@ -7,6 +7,7 @@ import torch
7
from vllm.attention.backends.abstract import AttentionBackend
8
from vllm.config import VllmConfig
9
from vllm.v1.attention.backends.utils import (
10
+ AttentionCGSupport,
11
AttentionMetadataBuilder,
12
CommonAttentionMetadata,
13
split_decodes_and_prefills,
@@ -35,6 +36,8 @@ class LinearAttentionMetadata:
36
class LinearAttentionMetadataBuilder(AttentionMetadataBuilder[LinearAttentionMetadata]):
37
reorder_batch_threshold: int = 1
38
39
+ _cudagraph_support = AttentionCGSupport.UNIFORM_SINGLE_TOKEN_DECODE
40
+
41
def __init__(
42
self,
43
kv_cache_spec: AttentionSpec,