@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / b42566f440
Fork 0

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 14, 05:30 UTC

[Bug] Fix `is_flashmla_supported` Check Error (#24774)

Signed-off-by: yewentao256 <zhyanwentao@126.com>

Wentao Ye committed Sep 15, 2025 at 22:10 UTC b42566f44039ed8dc5f6c124203d5d71740c6fe0
2 files changed +4 -26
vllm/attention/backends/flashmla.py
+2 -13
@@ -17,7 +17,6 @@ from vllm.attention.backends.mla.common import (MLACommonBackend,
17 from vllm.attention.ops.flashmla import (flash_mla_with_kvcache,
18 get_mla_metadata,
19 is_flashmla_supported)
20 -from vllm.platforms.cuda import CudaPlatform
20
21
22 class FlashMLABackend(MLACommonBackend):
@@ -179,18 +178,8 @@ class FlashMLAImpl(MLACommonImpl[FlashMLAMetadata]):
178 logits_soft_cap, attn_type,
179 kv_sharing_target_layer_name, **mla_args)
180
182 - assert is_flashmla_supported(), \
183 - "FlashMLA is not supported on this device"
184 -
185 - # disallow FlashMLA on NVIDIA Blackwell (SM 10.0+) GPUs
186 - # context:
187 - # https://github.com/deepseek-ai/FlashMLA/issues/83
188 - # https://github.com/vllm-project/vllm/issues/24513
189 - if CudaPlatform.has_device_capability(100):
190 - raise NotImplementedError(
191 - "FlashMLA is temporarily disabled on Blackwell (SM 10.0). "
192 - "Please use CUTLASS_MLA or TRITON_MLA instead. "
193 - "Example: `export VLLM_ATTENTION_BACKEND=CUTLASS_MLA`")
181 + is_supported, reason = is_flashmla_supported()
182 + assert is_supported, reason
183
184 unsupported_features = [alibi_slopes, sliding_window, logits_soft_cap]
185 if any(unsupported_features):
vllm/v1/attention/backends/mla/flashmla.py
+2 -13
@@ -12,7 +12,6 @@ from vllm.attention.ops.flashmla import (flash_mla_with_kvcache,
12 is_flashmla_supported)
13 from vllm.config import VllmConfig
14 from vllm.logger import init_logger
15 -from vllm.platforms.cuda import CudaPlatform
15 from vllm.v1.attention.backends.mla.common import (MLACommonBackend,
16 MLACommonDecodeMetadata,
17 MLACommonImpl,
@@ -156,18 +155,8 @@ class FlashMLAImpl(MLACommonImpl[FlashMLAMetadata]):
155 logits_soft_cap, attn_type,
156 kv_sharing_target_layer_name, **mla_args)
157
159 - assert is_flashmla_supported(), \
160 - "FlashMLA is not supported on this device"
161 -
162 - # disallow FlashMLA on NVIDIA Blackwell (SM 10.0+) GPUs
163 - # context:
164 - # https://github.com/deepseek-ai/FlashMLA/issues/83
165 - # https://github.com/vllm-project/vllm/issues/24513
166 - if CudaPlatform.has_device_capability(100):
167 - raise NotImplementedError(
168 - "FlashMLA is temporarily disabled on Blackwell (SM 10.0). "
169 - "Please use CUTLASS_MLA or TRITON_MLA instead. "
170 - "Example: `export VLLM_ATTENTION_BACKEND=CUTLASS_MLA`")
158 + is_supported, reason = is_flashmla_supported()
159 + assert is_supported, reason
160
161 unsupported_features = [alibi_slopes, sliding_window, logits_soft_cap]
162 if any(unsupported_features):