[Kernel] Strengthen kernel shape coverage (#29636)

Co-authored-by: Khoa Pham <khoa.pham@radixark.ai>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Mohammad Miadh Angkad <176301910+mmangkad@users.noreply.github.com>
This commit is contained in:
Xiaoyu Zhang
2026-07-01 15:44:20 +08:00
committed by GitHub
co-authored by Khoa Pham Claude Opus 4.8 Mohammad Miadh Angkad
parent 8205aa3603
commit df0dfbaa45
15 changed files with 378 additions and 145 deletions
+11 -5
View File
@@ -1,6 +1,6 @@
import itertools
import sys
from typing import Optional, Tuple
from typing import Tuple
import pytest
import torch
@@ -35,10 +35,16 @@ def sglang_per_token_quant_fp8(
return output, scale
@pytest.mark.parametrize(
"num_tokens,hidden_dim",
list(itertools.product([128, 256, 512], [512, 1076, 1368, 2048, 4096])),
)
PER_TOKEN_QUANT_CASES = list(
itertools.product([128, 256, 512], [512, 1076, 1368, 2048, 4096])
) + [
(39, 1536),
(1392, 1536),
(7807, 1536),
]
@pytest.mark.parametrize("num_tokens,hidden_dim", PER_TOKEN_QUANT_CASES)
def test_per_token_quant_compare_implementations(
num_tokens: int,
hidden_dim: int,