vllm.v1.worker.gpu.cp_utils ¶
Functions:
-
cp_local_slot–Return rank-local KV slots, or PAD_ID for positions not owned by this rank.
-
prepare_dcp_local_seq_lens–Populate the persistent DCP local seq_lens buffer (CUDA graph safe).
cp_local_slot(positions, block_numbers, block_size, cp_rank, CP_SIZE, CP_INTERLEAVE, PAD_ID) ¶
Return rank-local KV slots, or PAD_ID for positions not owned by this rank.
Source code in vllm/v1/worker/gpu/cp_utils.py
prepare_dcp_local_seq_lens(dcp_local_seq_lens, seq_lens, num_reqs, dcp_size, dcp_rank, cp_interleave) ¶
Populate the persistent DCP local seq_lens buffer (CUDA graph safe).