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
60e419c1
Unverified
Commit
60e419c1
authored
Oct 12, 2025
by
bnellnm
Committed by
GitHub
Oct 13, 2025
Browse files
[Misc] cache result of disable_inplace (#26666)
Signed-off-by:
Bill Nell
<
bnell@redhat.com
>
parent
7ef60528
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
vllm/model_executor/layers/fused_moe/utils.py
vllm/model_executor/layers/fused_moe/utils.py
+2
-0
No files found.
vllm/model_executor/layers/fused_moe/utils.py
View file @
60e419c1
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: Apache-2.0
# SPDX-FileCopyrightText: Copyright contributors to the vLLM project
# SPDX-FileCopyrightText: Copyright contributors to the vLLM project
import
functools
from
math
import
prod
from
math
import
prod
import
torch
import
torch
...
@@ -325,5 +326,6 @@ def activation_without_mul(activation: str) -> str:
...
@@ -325,5 +326,6 @@ def activation_without_mul(activation: str) -> str:
# Torch custom ops can't deal with outputs aliasing inputs so we need to
# Torch custom ops can't deal with outputs aliasing inputs so we need to
# disable inplace for torch >= 2.9.
# disable inplace for torch >= 2.9.
# See https://github.com/vllm-project/vllm/issues/26378
# See https://github.com/vllm-project/vllm/issues/26378
@
functools
.
cache
def
disable_inplace
()
->
bool
:
def
disable_inplace
()
->
bool
:
return
is_torch_equal_or_newer
(
"2.9"
)
return
is_torch_equal_or_newer
(
"2.9"
)
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