mirror of
https://github.com/deepseek-ai/DeepEP.git
synced 2026-11-05 00:47:32 +00:00
[GH-ISSUE #301] How does DeepEP prevent send queue overflows? #214
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
deepseek-ai/DeepEP#214
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @itayalroy on GitHub (Jul 14, 2025).
Original GitHub issue: https://github.com/deepseek-ai/DeepEP/issues/301
Hi guys, It doesn't look like dispatch/combine kernels (both in ll mode & regular mode) take send queue occupancy into account:
tail-headis allowed to be up to 256 (while it looks like qp size in nvshmem is hardcoded to 128), also there are atomic writes that consume wqes as wellHow does DeepEP prevent send queue overflow?
@sphish commented on GitHub (Jul 15, 2025):
The QP size in NVSHMEM is not hardcoded, it can be set by the env var
NVSHMEM_QP_DEPTH. In DeepEP, the variable is set to 1024 by default.For performance reasons, we have removed send queue polling. At the same time, we ensure that the number of inflight send wrs does not exceed the QP size to prevent overflow.
num_tokens / num_channels / send_chunk_size * 2.num_tokens + 1For the vast majority of practical cases, the QP size of 1024 is sufficient. If higher capacity is required, you can manually adjust it.