Skip to content

Commit 563b8ea

Browse files
authored
fix
1 parent 72bc69f commit 563b8ea

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

lightllm/common/basemodel/layer_weights/meta_weights/fused_moe_weight_ep.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -360,8 +360,7 @@ def prefilled_group_gemm(
360360
# here is used to match autotune feature, make moe model run same triton kernel in different rank.
361361
# in some special case, one rank will recv 0 token, so add a token to make it run triton kernel.
362362
if (
363-
get_triton_autotune_level() != AutotuneLevel.NO_AUTOTUNE
364-
and get_triton_autotune_level() != AutotuneLevel.CLOSE_AUTOTUNE
363+
get_triton_autotune_level() in [AutotuneLevel.ADAPTIVE_AUTOTUNE, AutotuneLevel.FORCE_AUTOTUNE]
365364
):
366365
_gemm_out_a = torch.zeros((1, N), device=device, dtype=hidden_dtype)
367366
_silu_out = torch.zeros((1, N // 2), device=device, dtype=hidden_dtype)

lightllm/common/fused_moe/grouped_fused_moe_ep.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,7 @@ def fused_experts_impl(
193193
# here is used to match autotune feature, make moe model run same triton kernel in different rank.
194194
# in some special case, one rank will recv 0 token, so add a token to make it run triton kernel.
195195
if (
196-
get_triton_autotune_level() != AutotuneLevel.NO_AUTOTUNE
197-
and get_triton_autotune_level() != AutotuneLevel.CLOSE_AUTOTUNE
196+
get_triton_autotune_level() in [AutotuneLevel.ADAPTIVE_AUTOTUNE, AutotuneLevel.FORCE_AUTOTUNE]
198197
):
199198
_gemm_out_a = torch.zeros((1, N), device=hidden_states.device, dtype=hidden_states.dtype)
200199
_silu_out = torch.zeros((1, N // 2), device=hidden_states.device, dtype=hidden_states.dtype)

0 commit comments

Comments
 (0)