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
FlashMLA
Commits
79408d6d
Commit
79408d6d
authored
May 21, 2026
by
zhanghj2
Browse files
update error info
parent
92a05388
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
csrc/extension/flash_api.h
csrc/extension/flash_api.h
+4
-4
No files found.
csrc/extension/flash_api.h
View file @
79408d6d
...
...
@@ -61,9 +61,9 @@ mha_fwd_kvcache_quantization_mla(
auto
q_dtype
=
q
.
dtype
();
if
(
kv_cache_dtype
==
"fp8_e4m3"
||
kv_cache_dtype
==
"fp8_e5m2"
)
{
TORCH_CHECK
(
kcache
.
dtype
()
!=
q_dtype
,
"
非量化情况下
, query and key must have not the same dtype"
);
TORCH_CHECK
(
kcache
.
dtype
()
!=
q_dtype
,
"
mha_fwd_kvcache_quantization_mla
, query and key must have not the same dtype"
);
CHECK_DEVICE
(
k_scale
);
TORCH_CHECK
(
k_scale
.
dtype
()
==
torch
::
kFloat32
,
"
非量化情况下, query and key must have the same dtype
"
);
TORCH_CHECK
(
k_scale
.
dtype
()
==
torch
::
kFloat32
,
"
k_scale, dtype error
"
);
// TORCH_CHECK(is_gfx936, "fp8_e4m3 and fp8_e5m2 Attention Forward Kernel (mha_fwd_kvcache_quantization_mla) is only supported on gfx936 architectures");
}
else
...
...
@@ -516,9 +516,9 @@ mha_fwd_kvcache_quantization_q_nope_pe_mla(
auto
q_dtype
=
q_nope
.
dtype
();
if
(
kv_cache_dtype
==
"fp8_e5m2"
)
{
TORCH_CHECK
(
kcache
.
dtype
()
!=
q_dtype
,
"
非量化情况下
, query and key must have not the same dtype"
);
TORCH_CHECK
(
kcache
.
dtype
()
!=
q_dtype
,
"
mha_fwd_kvcache_quantization_q_nope_pe_mla
, query and key must have not the same dtype"
);
CHECK_DEVICE
(
k_scale
);
TORCH_CHECK
(
k_scale
.
dtype
()
==
torch
::
kFloat32
,
"
非量化情况下, query and key must have the sam
e dtype"
);
TORCH_CHECK
(
k_scale
.
dtype
()
==
torch
::
kFloat32
,
"
mha_fwd_kvcache_quantization_q_nope_pe_mla, k_scal
e dtype
error
"
);
}
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