#56107 [PCP][Spec Decode] Adds PCP support for single-module MTP and replicated DSpark.
原始 PR · 作者 LucasWilkinson · 合并时间 2026-09-11 13:07
PCP 下解锁单模块 MTP 与 DSpark 投机解码
值得精读,尤其是负责 MRv2、PCP/DCP 与投机解码的工程师。重点看三处:(1) `PCPManager.prepare_draft_prefill` / `restore_draft_prefill` 定义的“首个 draft forward 复用 rank-local batch、后续 replicated draft 刷新全局 block table”契约,这是本 PR 的核心设计决策;(2) `partition_batch` 中 positions / seq_lens / logits_indices 的重写(positions 必须来自 GPU 全局 batch、本地 logits 不再采样),它解释了为什么必须移除 `req_states` 依赖;(3) `sparse_attn_indexer.py` 与 `check_attention_cp_compatibility` 的口径放宽,判断是否接受这种“隐式形状判定 + 校验只覆盖 target 层”的取舍。若要在生产启用,建议先补一条 PCP + MTP/DSpark 的 e2e 用例,并重跑作者未完成的整模型 acceptance 验证(含 dummy/profile 路径)。
参与讨论