Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
9ff3592b
Commit
9ff3592b
authored
Aug 09, 2025
by
zhuwenwen
Browse files
Revert "已修改 vllm/utils/__init__.py"
This reverts commit
20b6cf64
.
parent
dcec1430
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
vllm/utils/__init__.py
vllm/utils/__init__.py
+7
-7
No files found.
vllm/utils/__init__.py
View file @
9ff3592b
...
...
@@ -1173,11 +1173,12 @@ def find_nccl_library() -> str:
prev_set_stream
=
torch
.
cuda
.
set_stream
_current_stream
_tls
=
threading
.
local
()
_current_stream
=
None
def
_patched_set_stream
(
stream
:
torch
.
cuda
.
Stream
)
->
None
:
_current_stream_tls
.
value
=
stream
global
_current_stream
_current_stream
=
stream
prev_set_stream
(
stream
)
...
...
@@ -1196,8 +1197,8 @@ def current_stream() -> torch.cuda.Stream:
from C/C++ code.
"""
from
vllm.platforms
import
current_platform
if
not
hasattr
(
_current_stream
_tls
,
"value"
)
or
_current_stream
_tls
.
value
is
None
:
global
_current_stream
if
_current_stream
is
None
:
# when this function is called before any stream is set,
# we return the default stream.
# On ROCm using the default 0 stream in combination with RCCL
...
...
@@ -1207,9 +1208,8 @@ def current_stream() -> torch.cuda.Stream:
# fix computational precision issue in eager mode
# _current_stream = torch.cuda.Stream() if current_platform.is_rocm(
# ) else torch.cuda.current_stream()
_current_stream_tls
.
value
=
torch
.
cuda
.
Stream
(
)
if
current_platform
.
is_rocm
()
else
torch
.
cuda
.
current_stream
()
return
_current_stream_tls
.
value
_current_stream
=
torch
.
cuda
.
current_stream
()
return
_current_stream
def
enable_trace_function_call_for_thread
(
vllm_config
:
VllmConfig
)
->
None
:
...
...
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