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
625b0b5e
Commit
625b0b5e
authored
Jan 23, 2026
by
zhuwenwen
Browse files
only support fp8 e4m3 on nmz
parent
a3488ab0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
vllm/v1/attention/backends/flash_attn.py
vllm/v1/attention/backends/flash_attn.py
+4
-1
No files found.
vllm/v1/attention/backends/flash_attn.py
View file @
625b0b5e
...
@@ -142,7 +142,10 @@ class FlashAttentionBackend(AttentionBackend):
...
@@ -142,7 +142,10 @@ class FlashAttentionBackend(AttentionBackend):
@
staticmethod
@
staticmethod
def
get_fp8_dtype_for_flashattn
(
kv_cache_dtype
:
str
)
->
torch
.
dtype
:
def
get_fp8_dtype_for_flashattn
(
kv_cache_dtype
:
str
)
->
torch
.
dtype
:
if
kv_cache_dtype
in
(
"fp8"
,
"fp8_e4m3"
):
if
kv_cache_dtype
in
(
"fp8"
,
"fp8_e4m3"
):
return
torch
.
float8_e4m3fn
if
torch
.
cuda
.
get_device_properties
(
"cuda"
).
gcnArchName
.
split
(
':'
)[
0
]
==
"gfx938"
:
return
torch
.
float8_e4m3fn
else
:
raise
ValueError
(
f
"Unsupported FP8 dtype:
{
kv_cache_dtype
}
"
)
elif
kv_cache_dtype
in
(
"fp8_e5m2"
):
elif
kv_cache_dtype
in
(
"fp8_e5m2"
):
return
torch
.
float8_e5m2
return
torch
.
float8_e5m2
else
:
else
:
...
...
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