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
ddc2001f
"src/vscode:/vscode.git/clone" did not exist on "f941fc9917804941456efbfa5fff1024346d329d"
Unverified
Commit
ddc2001f
authored
Jan 22, 2025
by
Hui Liu
Committed by
GitHub
Jan 22, 2025
Browse files
disable custom allreduce on HIP (#3058)
parent
806a3002
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
python/sglang/srt/distributed/parallel_state.py
python/sglang/srt/distributed/parallel_state.py
+4
-0
No files found.
python/sglang/srt/distributed/parallel_state.py
View file @
ddc2001f
...
@@ -41,6 +41,7 @@ from torch.distributed import Backend, ProcessGroup
...
@@ -41,6 +41,7 @@ from torch.distributed import Backend, ProcessGroup
from
sglang.srt.utils
import
(
from
sglang.srt.utils
import
(
direct_register_custom_op
,
direct_register_custom_op
,
is_cuda_alike
,
is_cuda_alike
,
is_hip
,
supports_custom_op
,
supports_custom_op
,
)
)
...
@@ -952,6 +953,9 @@ _ENABLE_CUSTOM_ALL_REDUCE = True
...
@@ -952,6 +953,9 @@ _ENABLE_CUSTOM_ALL_REDUCE = True
def
set_custom_all_reduce
(
enable
:
bool
):
def
set_custom_all_reduce
(
enable
:
bool
):
global
_ENABLE_CUSTOM_ALL_REDUCE
global
_ENABLE_CUSTOM_ALL_REDUCE
_ENABLE_CUSTOM_ALL_REDUCE
=
enable
_ENABLE_CUSTOM_ALL_REDUCE
=
enable
if
enable
and
is_hip
():
logger
.
warning
(
"HIP doesn't support custom_all_reduce, so disable it."
)
_ENABLE_CUSTOM_ALL_REDUCE
=
False
def
init_distributed_environment
(
def
init_distributed_environment
(
...
...
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