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 11, 16:15 UTC
[ROCm] Fix broken import in platform attention backend dispatching (#30432)
Signed-off-by: Andreas Karatzas <akaratza@amd.com>
Andreas Karatzas committed
Dec 10, 2025 at 19:12 UTC
b51255f369cf45456e3062e32ecbfebd03a9f169
1 file changed
+15
-1
vllm/platforms/rocm.py
+15
-1
@@ -403,7 +403,21 @@ class RocmPlatform(Platform):
403
compilation_config.cudagraph_mode = CUDAGraphMode.PIECEWISE
404
405
if cache_config and cache_config.block_size is None:
406
- cache_config.block_size = 16
406
+ if (
407
+ envs.VLLM_ROCM_USE_AITER_UNIFIED_ATTENTION and envs.VLLM_ROCM_USE_AITER
408
+ # NOTE: This block has been deprecated
409
+ # or get_env_variable_attn_backend()
410
+ # == AttentionBackendEnum.ROCM_AITER_UNIFIED_ATTN
411
+ # TODO: monitor https://github.com/vllm-project/vllm/pull/30396
412
+ # to see how we can transition to the new way of selecting
413
+ # attention backends
414
+ ):
415
+ cache_config.block_size = 64
416
+ logger.warning(
417
+ "[ROCM_AITER_UNIFIED_ATTN]: Setting kv cache block size to 64."
418
+ )
419
+ else:
420
+ cache_config.block_size = 16
421
422
if parallel_config.worker_cls == "auto":
423
parallel_config.worker_cls = "vllm.v1.worker.gpu_worker.Worker"