fix(modelopt_fp4): skip NVFP4 swiglu-fusion interleave for shared experts with swiglu_limit (#37378)
This commit is contained in:
@@ -787,6 +787,7 @@ class DeepseekV2MoE(nn.Module):
|
|||||||
ModelOptFp4LinearMethod,
|
ModelOptFp4LinearMethod,
|
||||||
)
|
)
|
||||||
and fc1_n % 128 == 0
|
and fc1_n % 128 == 0
|
||||||
|
and self.shared_experts.swiglu_limit is None
|
||||||
and not check_cuda_graph_backend(Phase.PREFILL, Backend.TC_PIECEWISE)
|
and not check_cuda_graph_backend(Phase.PREFILL, Backend.TC_PIECEWISE)
|
||||||
):
|
):
|
||||||
self.shared_experts.gate_up_proj._interleave_for_swiglu_fusion = True
|
self.shared_experts.gate_up_proj._interleave_for_swiglu_fusion = True
|
||||||
|
|||||||
Reference in New Issue
Block a user