Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the moe padding conditional logic #4081

Merged
merged 5 commits into from
Mar 5, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
from sglang.srt.layers.quantization.int8_kernel import per_token_group_quant_int8
from sglang.srt.utils import (
direct_register_custom_op,
get_bool_env_var,
get_device_name,
is_cuda_available,
is_hip,
Expand Down Expand Up @@ -941,7 +942,11 @@ def fused_experts_impl(
no_combine: bool = False,
):
padded_size = padding_size
if not use_fp8_w8a8 or not use_int8_w8a8 or block_shape is not None:
if (
not (use_fp8_w8a8 or use_int8_w8a8)
or block_shape is not None
or (is_hip_ and get_bool_env_var("CK_MOE"))
):
padded_size = 0

# Check constraints.
Expand Down
Loading