Bug Description
The warmup process miscalculates KV cache memory for hybrid GDN (GatedDeltaNet) + FullAttention models, causing OOM during graph compilation. The warmup graph compilation for 300+ buckets requires ~20-30 GiB peak, but the KV cache for hybrid models with long context (262K) consumes most of the available HBM, leaving insufficient memory for warmup graphs.
Environment
- Image:
vault.habana.ai/gaudi-docker/1.24.1/ubuntu24.04/habanalabs/vllm-0.24.0-ptupstream-2.11.0:latest (also tested on v0.26.0)
- vLLM version: v0.24.0 and v0.26.0
- Gaudi software: v1.24.1 (PyTorch 2.11)
- Model:
bottlecapai/ThinkingCap-Qwen3.6-27B-FP8 (hybrid: FullAttention + GDN layers)
- Configuration: TP=4, max-model-len=262144, kv-cache-dtype=fp8_inc
Problem Details
With a hybrid GDN model and 262K context:
- Total HBM per card: ~126.5 GiB
- Model weights: ~7.1 GiB
- KV cache (without VLLM_COMPACT_GDN): ~108 GiB — GDN state scales with block count, effectively doubling KV cache size
- Remaining for warmup: ~18 GiB
- Warmup graph compilation (300+ buckets): requires ~20-30 GiB peak → OOM
Even with VLLM_COMPACT_GDN=true and VLLM_GRAPH_RESERVED_MEM=0.25 (reserving 25% of HBM for warmup graphs), the warmup barely fits. However, reserving 25% of HBM (~31 GiB) for warmup graphs is extremely wasteful — that memory could be used for KV cache and serving more concurrent requests.
Error
allocation failed for 768MB
(OOM during warmup graph compilation when KV cache consumed most of HBM)
Workaround
Set VLLM_SKIP_WARMUP=true to skip warmup entirely. Graphs compile on-demand for real request shapes, which uses much less memory since real request batch sizes are smaller than the worst-case warmup buckets.
Suggested Fix
The warmup memory budget calculation should account for the GDN state cache memory overhead in hybrid models. Either:
- Correctly estimate GDN state memory when calculating available memory for warmup graphs
- Allow warmup to use a dynamic memory budget that adapts to the actual KV cache + GDN state usage
- Provide a more granular way to limit warmup memory without reserving a fixed percentage of total HBM
Related
Bug Description
The warmup process miscalculates KV cache memory for hybrid GDN (GatedDeltaNet) + FullAttention models, causing OOM during graph compilation. The warmup graph compilation for 300+ buckets requires ~20-30 GiB peak, but the KV cache for hybrid models with long context (262K) consumes most of the available HBM, leaving insufficient memory for warmup graphs.
Environment
vault.habana.ai/gaudi-docker/1.24.1/ubuntu24.04/habanalabs/vllm-0.24.0-ptupstream-2.11.0:latest(also tested on v0.26.0)bottlecapai/ThinkingCap-Qwen3.6-27B-FP8(hybrid: FullAttention + GDN layers)Problem Details
With a hybrid GDN model and 262K context:
Even with
VLLM_COMPACT_GDN=trueandVLLM_GRAPH_RESERVED_MEM=0.25(reserving 25% of HBM for warmup graphs), the warmup barely fits. However, reserving 25% of HBM (~31 GiB) for warmup graphs is extremely wasteful — that memory could be used for KV cache and serving more concurrent requests.Error
(OOM during warmup graph compilation when KV cache consumed most of HBM)
Workaround
Set
VLLM_SKIP_WARMUP=trueto skip warmup entirely. Graphs compile on-demand for real request shapes, which uses much less memory since real request batch sizes are smaller than the worst-case warmup buckets.Suggested Fix
The warmup memory budget calculation should account for the GDN state cache memory overhead in hybrid models. Either:
Related