[KV Offload] Pass OffloadingSpec instead of VllmConfig to secondary tiers (#43076)

Signed-off-by: Ronen Schaffer <ronen.schaffer@ibm.com>
This commit is contained in:
Ronen Schaffer
2026-05-20 03:32:08 +00:00
committed by GitHub
parent cd0ff26e7a
commit 4f940896a3
5 changed files with 15 additions and 15 deletions
@@ -29,7 +29,7 @@ from vllm.v1.kv_offload.tiering.manager import (
)
_CTX = ReqContext(req_id="test")
_MOCK_VLLM_CONFIG = MagicMock()
_MOCK_OFFLOADING_SPEC = MagicMock()
def _mock_mmap_region(num_blocks: int, row_bytes: int = 16):
@@ -68,7 +68,7 @@ class TestExampleSecondaryTierManager:
"""Test basic store and lookup operations."""
mock_view = memoryview(torch.zeros((10, 16), dtype=torch.int8).numpy())
tier = ExampleSecondaryTierManager(
vllm_config=_MOCK_VLLM_CONFIG,
offloading_spec=_MOCK_OFFLOADING_SPEC,
primary_kv_view=mock_view,
tier_type="example",
custom_param=67,
@@ -105,12 +105,12 @@ class TestTieringOffloadingManager:
# Create secondary tiers with the primary view
self.secondary_tier1 = ExampleSecondaryTierManager(
vllm_config=_MOCK_VLLM_CONFIG,
offloading_spec=_MOCK_OFFLOADING_SPEC,
primary_kv_view=mock_view,
tier_type="example",
)
self.secondary_tier2 = ExampleSecondaryTierManager(
vllm_config=_MOCK_VLLM_CONFIG,
offloading_spec=_MOCK_OFFLOADING_SPEC,
primary_kv_view=mock_view,
tier_type="example",
)