Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
change
sglang
Commits
98457c04
Unverified
Commit
98457c04
authored
Aug 14, 2025
by
Huaixin Chang
Committed by
GitHub
Aug 13, 2025
Browse files
[Bugfix] Avoid unnecessary reduce-scatter call in prepare_mlp (#9169)
parent
0fc8bf2c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
python/sglang/srt/layers/dp_attention.py
python/sglang/srt/layers/dp_attention.py
+4
-0
No files found.
python/sglang/srt/layers/dp_attention.py
View file @
98457c04
...
...
@@ -292,6 +292,10 @@ def _dp_gather_via_all_gather(
forward_batch
:
ForwardBatch
,
is_partial
:
bool
,
):
if
get_attention_tp_size
()
==
1
:
get_tp_group
().
all_gather_into_tensor
(
global_tokens
,
local_tokens
)
return
if
not
is_partial
:
if
get_attention_tp_rank
()
!=
0
:
local_tokens
.
fill_
(
0
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment