[ROCm][CI] fix flashinfer import check (#48647)

Signed-off-by: Divakar Verma <divakar.verma@amd.com>
This commit is contained in:
Divakar Verma
2026-07-14 20:54:19 +00:00
committed by GitHub
parent 0b54201a04
commit 05d4f8bba3
@@ -3,11 +3,16 @@
"""FlashInfer GQA builder: reorder threshold under DCP with spec decode."""
import pytest
from vllm.platforms import current_platform
if not current_platform.is_cuda():
pytest.skip("FlashInfer backend requires a CUDA platform.", allow_module_level=True)
import torch
from tests.v1.attention.utils import create_vllm_config
from vllm.config import SpeculativeConfig, set_current_vllm_config
from vllm.platforms import current_platform
from vllm.v1.attention.backends import flashinfer as flashinfer_backend
from vllm.v1.attention.backends.flashinfer import (
FlashInferDecodeKernel,
@@ -16,9 +21,6 @@ from vllm.v1.attention.backends.flashinfer import (
from vllm.v1.attention.backends.utils import PerLayerParameters
from vllm.v1.kv_cache_interface import FullAttentionSpec
if not current_platform.is_cuda():
pytest.skip("FlashInfer backend requires a CUDA platform.", allow_module_level=True)
def test_flashinfer_gqa_dcp_spec_decode_clamps_reorder_threshold(monkeypatch):
"""trtllm-gen decode receives no cp_rank/global-seq-len information, so its