fix: expert_offsets for 4-expert fused SwiGLU test

This commit is contained in:
2026-06-02 08:24:32 +00:00
parent 53362d2579
commit 5ed4c86137

View File

@@ -74,8 +74,9 @@ def test_fused_swiglu_compilation():
w_fp4_il = interleave_l1_weights(w_fp4)
mat_b = make_b_k_major(w_fp4_il)
# Expert offsets: all 128 tokens in expert 0
padded_offsets = torch.tensor([128], dtype=torch.int32, device=device)
# Expert offsets: all 128 tokens in expert 0, others have 0
# For 4 experts: offsets = [128, 128, 128, 128] (cumulative)
padded_offsets = torch.tensor([128, 128, 128, 128], dtype=torch.int32, device=device)
# Scale assembly
K_sf = cutedsl_ceil_div(K, 16)