Skip to content

vllm.v1.worker.cpu.block_table

Classes:

CPUBlockTables

Methods:

gather_block_tables(idx_mapping, num_reqs_padded, out=None, num_computed_tokens=None)

Gather the batch's block-table rows into the forward-pass tables.

When num_computed_tokens ([max_num_reqs], indexed like the block tables) is given, sliding-window groups get every entry wholly below the window of the request's first scheduled token replaced by the null block. Those blocks may already have been freed by the sliding-window manager and reused, while attention kernels can still load them as part of a KV tile that straddles the window start: masked-out NaN in such a tile propagates into the output.