[Attention][DCP] Support a2a DCP comm backend for FlashMLA sparse (#61285)
Signed-off-by: NickLucche <nicolo.lucchesi@mistral.ai> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
380638afbb
commit
86b1c2ef15
@@ -446,12 +446,6 @@ class FlashMLASparseMetadataBuilder(
|
||||
)
|
||||
|
||||
if parallel_config.decode_context_parallel_size > 1:
|
||||
if parallel_config.dcp_comm_backend != "ag_rs":
|
||||
raise NotImplementedError(
|
||||
"DCP for FlashMLA sparse is only validated with the "
|
||||
"default 'ag_rs' DCP comm backend; got "
|
||||
f"'{parallel_config.dcp_comm_backend}'"
|
||||
)
|
||||
if self.pcp_dcp_kv_gather and cache_config.cache_dtype != "fp8_ds_mla":
|
||||
raise NotImplementedError(
|
||||
"PCP+DCP sparse prefill gathers the KV through the fp8_ds_mla "
|
||||
@@ -1268,7 +1262,7 @@ class FlashMLASparseImpl(SparseMLACommonImpl[FlashMLASparseMetadata]):
|
||||
out.masked_fill_(empty_rows.view(-1, 1, 1), 0.0)
|
||||
lse.masked_fill_(empty_rows.view(-1, 1), float("-inf"))
|
||||
# The head-padding slice above can leave `out` non-contiguous, and the
|
||||
# merge feeds it to reduce_scatter.
|
||||
# DCP combines (reduce_scatter, direct A2A) need packed heads.
|
||||
return out.contiguous(), lse
|
||||
|
||||
def _fp8_flash_mla_kernel(
|
||||
|
||||
Reference in New Issue
Block a user