[KV] Side-cache layout -- fold the PLE state into a GDN group, pack QSA rings

The packed pool strides every block by the widest group, and every group draws whole blocks. The PLE short-conv
state now shares a GDN cache group, and the QSA raw-key rings are packed as equal slots inside shared blocks, so
neither holds a whole block per request. VLLM_E2_SIDE_CACHE_LAYOUT (default 1) selects the old layout with 0.
On its own the layout raises the Flash-Next pool from 806,792 to 853,994 tokens at the same budget.

Co-Authored-By: Hinata <hinata@idihore.id>
Signed-off-by: MOVZX <movzx@yahoo.com>
This commit is contained in:
2026-10-09 20:15:11 +07:00
co-authored by Hinata
parent 21fb7de7bf
commit 72485816d9
10 changed files with 3513 additions and 10 deletions
+4
View File
@@ -1619,6 +1619,10 @@ class Scheduler(SchedulerInterface):
pending = set(block_ids)
owners: dict[int, set[str]] = {}
for mgr in self.kv_cache_manager.coordinator.single_type_managers:
if getattr(mgr, "slot_pool", None) is not None:
# v2.5 slot-packed ring: its block ids are slot ids, not pool
# block ids, and its pages are never zeroed.
continue
for req_id, blocks in mgr.req_to_blocks.items():
for blk in blocks:
if blk.block_id in pending: