@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / 180fba653e
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 9, 20:45 UTC

[ROCm] fix import for on_gfx9 (#32783)

Signed-off-by: Divakar Verma <divakar.verma@amd.com>

Divakar Verma committed Jan 21, 2026 at 12:41 UTC 180fba653ead2274bfcd3951a275f4d6cf9ade04
2 files changed +16 -2
vllm/model_executor/layers/fused_moe/fused_batched_moe.py
+8 -1
@@ -913,7 +913,14 @@ class BatchedTritonExperts(mk.FusedMoEPermuteExpertsUnpermute):
913 activation_key: QuantKey | None,
914 ) -> bool:
915 p = current_platform
916 - device_supports_fp8 = (p.is_rocm() and p.rocm.on_gfx9()) or (
916 + if p.is_rocm():
917 + from vllm.platforms.rocm import on_gfx9
918 +
919 + is_rocm_on_gfx9 = on_gfx9()
920 + else:
921 + is_rocm_on_gfx9 = False
922 +
923 + device_supports_fp8 = is_rocm_on_gfx9 or (
924 p.is_cuda() and p.has_device_capability((8, 9))
925 )
926
vllm/model_executor/layers/fused_moe/fused_moe.py
+8 -1
@@ -1922,7 +1922,14 @@ class TritonExperts(mk.FusedMoEPermuteExpertsUnpermute):
1922 activation_key: QuantKey | None,
1923 ) -> bool:
1924 p = current_platform
1925 - device_supports_fp8 = (p.is_rocm() and p.rocm.on_gfx9()) or (
1925 + if p.is_rocm():
1926 + from vllm.platforms.rocm import on_gfx9
1927 +
1928 + is_rocm_on_gfx9 = on_gfx9()
1929 + else:
1930 + is_rocm_on_gfx9 = False
1931 +
1932 + device_supports_fp8 = is_rocm_on_gfx9 or (
1933 p.is_cuda() and p.has_device_capability((8, 9))
1934 )
1935