From eb8e5dd49fce99d9e10c4be761d0d1dcdca73959 Mon Sep 17 00:00:00 2001 From: LiangSu8899 <1342163629@qq.com> Date: Tue, 4 Aug 2026 12:58:43 +0000 Subject: [PATCH 1/3] feat(flashrt-vocab-ce-train): expose documented vocab_ce_loss public API The README/CARD document vocab_ce_loss as the public training API but the package only exposed vocab_ce. Add the documented alias (delegating to vocab_ce) and re-run the installed smoke/full suites (2/2 pass). --- .../torch-ext/flashrt_vocab_ce_train/__init__.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/flashrt-vocab-ce-train/torch-ext/flashrt_vocab_ce_train/__init__.py b/flashrt-vocab-ce-train/torch-ext/flashrt_vocab_ce_train/__init__.py index bcc15c7..66eac82 100644 --- a/flashrt-vocab-ce-train/torch-ext/flashrt_vocab_ce_train/__init__.py +++ b/flashrt-vocab-ce-train/torch-ext/flashrt_vocab_ce_train/__init__.py @@ -162,10 +162,21 @@ def vocab_ce( ) +def vocab_ce_loss( + hidden: torch.Tensor, + weight: torch.Tensor, + labels: torch.Tensor, + z_loss_weight: float = 0.0, + ignore_index: int = -100, +) -> torch.Tensor: + """Documented public alias of :func:`vocab_ce` (README/CARD API).""" + return vocab_ce(hidden, weight, labels, z_loss_weight, ignore_index) + + def backend_marker(x: torch.Tensor) -> torch.Tensor: if ops is None: return x return ops._flashrt_training_package_marker(x) -__all__ = ["vocab_ce", "reference_vocab_ce", "backend_marker"] +__all__ = ["vocab_ce", "vocab_ce_loss", "reference_vocab_ce", "backend_marker"] From 9dd9f7f1dedf7abffdd0fa69125476009a5e833b Mon Sep 17 00:00:00 2001 From: LiangSu8899 <1342163629@qq.com> Date: Tue, 4 Aug 2026 12:58:45 +0000 Subject: [PATCH 2/3] fix(sageattention2-blackwell): accept SM110 in Blackwell capability gate The test gate required major>=12, rejecting Thor (sm_110, major 11) even though all six kernels pass on-device. Accept the full Blackwell family (sm_100/103/110/120); the widened gate passes 9/9 full rows on Thor (fp8v rows cos>=0.9992). --- .../tests/test_sageattention2_blackwell.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sageattention2-blackwell/tests/test_sageattention2_blackwell.py b/sageattention2-blackwell/tests/test_sageattention2_blackwell.py index dcbf8d0..f48f648 100644 --- a/sageattention2-blackwell/tests/test_sageattention2_blackwell.py +++ b/sageattention2-blackwell/tests/test_sageattention2_blackwell.py @@ -221,8 +221,8 @@ def main() -> None: if not torch.cuda.is_available(): raise SystemExit("CUDA is required") - major, _minor = torch.cuda.get_device_capability(0) - if major < 12: + major, minor = torch.cuda.get_device_capability(0) + if major not in (10, 11, 12) or (major == 10 and minor not in (0, 3)): raise SystemExit("sageattention2-blackwell requires Blackwell-class CUDA capability") torch.manual_seed(2026) From a4e94287de166de8e1e870424c8661fba1320e7c Mon Sep 17 00:00:00 2001 From: LiangSu8899 <1342163629@qq.com> Date: Tue, 4 Aug 2026 12:58:40 +0000 Subject: [PATCH 3/3] docs(fp8-cross-attention-blackwell): record installed-artifact SM110 validation Built for sm_110a with CUTLASS 4.4 (the declared cutlass_4_4 dependency; 4.5.x moved SM100_MMA_F8F6F4_SS to a class template and breaks csrc/fmha77) and closed the installed-artifact gate on Thor: 9/9 rows plus rejection, CUDA Graph replay, and torch.compile pass; production B1,Sq786,Sk7984 row cos=0.999786. --- fp8-cross-attention-blackwell/VALIDATION.md | 25 +++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/fp8-cross-attention-blackwell/VALIDATION.md b/fp8-cross-attention-blackwell/VALIDATION.md index 62ff36c..19eac82 100644 --- a/fp8-cross-attention-blackwell/VALIDATION.md +++ b/fp8-cross-attention-blackwell/VALIDATION.md @@ -20,3 +20,28 @@ both sides of every 128-token boundary are release blockers. Installed-artifact correctness and `torch.compile(fullgraph=True)` remain mandatory after the HF Jobs build. Source validation does not replace them. + +## Installed artifact on NVIDIA Thor (SM110) + +The installed-artifact gate (missing when this card was written) is now closed +on Thor `sm_110a`. Build notes: + +- Requires CUTLASS **4.4.0** (the package declares `cutlass_4_4`); 4.5.x moved + `SM100_MMA_F8F6F4_SS` to a class template and breaks `csrc/fmha77`. +- `cutlass/util/packed_stride.hpp` is vendored by `fp4-gemm` and must be on the + include path (same local-build workaround as `fp8-gemm`). +- Compiled with `-gencode arch=compute_110a` and the FMHA sm100 kernel runs + natively on Thor (no fallback required, unlike `fused-mlp-megakernels`). + +Command: + +```bash +python fp8-cross-attention-blackwell/tests/test_fp8_cross_attention_blackwell.py \ + --backend installed --artifact --mode full +``` + +Result: 9/9 numeric rows, invalid-head rejection, CUDA Graph replay, and +`torch.compile(fullgraph=True)` all passed on SM110. Worst row across the +matrix (`B1,Sq786,Sk7984,Hq28,Hkv4,D128`): `max=0.00025749`, `p99=0.00012207`, +`mean=0.00003710`, `cosine=0.99978602` — comfortably inside the +`max<=0.004 / cosine>=0.9995` gate. Other rows held `cosine>=0.999778`.