Commit Graph

224 Commits

Author SHA1 Message Date
085d72ea8f D1: Full test with TMEM-P at hd=64,128,256,512 2026-05-24 04:07:40 +00:00
96a52e63e9 D1: SMEM-P test at hd=128 2026-05-24 03:48:37 +00:00
0f52c3453c D1: Fix SMEM-P (coordinate store), LSE (FP32), add TMEM-P-only test 2026-05-24 03:27:14 +00:00
e1a5077fda D1: LSE diagnostic at various hd 2026-05-24 03:23:16 +00:00
efe6f4dff8 D1: Add diagnostic test (TMEM-P vs SMEM-P at various hd) 2026-05-24 03:22:23 +00:00
7142e459cc D1 test: compare un-norm O + norm using ref row_sum + LSE verification 2026-05-24 03:21:01 +00:00
153db24be2 D1.5: Always output un-normalized O + LSE (epilogue_tma_store only, no TMEM round-trip normalize) 2026-05-24 03:18:38 +00:00
974cddbf7b test: add try/except for SMEM-P coord test 2026-05-24 02:15:07 +00:00
5fd556db63 test: use FmhaKernel for SMEM-P coord test 2026-05-24 01:59:25 +00:00
e50ba7212c test: SMEM-P coordinate verification test 2026-05-24 01:58:32 +00:00
3325d7442c fix: proper v_major from tensor 2026-05-24 01:55:37 +00:00
f2dd36cd4b fix: COL_MAJOR 2026-05-24 01:54:30 +00:00
c815560d64 fix: hardcode v_major for diag test 2026-05-24 01:54:20 +00:00
34fe43a551 diag: use FmhaKernel setup for cotiled test 2026-05-24 01:54:08 +00:00
7a9881ab82 fix: v_major derivation in cotiled diag 2026-05-24 01:53:40 +00:00
a5fbc6cebd diag: simplified cotiled layout test 2026-05-24 01:53:24 +00:00
60ff5e4f53 fix: LayoutEnum import in cotiled diag test 2026-05-24 01:52:58 +00:00
7113da195b diag: layout composition test for make_cotiled_copy SMEM-P 2026-05-24 01:48:50 +00:00
8514a72ba0 D1.5: Replace TMEM round-trip normalize with correction epilog (one-way: TMEM→reg→SMEM→GMEM)
- Remove noop + normalize TMEM round-trips (3% error per trip)
- Use epilogue_tmem_copy_and_partition for TMEM→reg (paired atoms)
- Use epilogue_smem_copy_and_partition for reg→SMEM (paired atoms)
- Apply 1/row_sum normalization in register space (exact)
- TMA store from SMEM→GMEM (no TMEM write-back)
- Add iter_acc_early_release_in_epilogue attribute
- Update SMEM-P comments to reflect coordinate-indexed fallback
2026-05-24 00:24:24 +00:00
f259fafcae D1.3: Add unnormalized debug test to isolate SMEM-P vs O round-trip error 2026-05-24 00:15:41 +00:00
b72062e47c D1.3: Add SMEM-P write/read diagnostic 2026-05-24 00:13:28 +00:00
6d6b91dcb4 D1.3: Add SMEM-P vs TMEM-P comparison test 2026-05-24 00:10:18 +00:00
f1b8fef3a2 D1.3: Fix while loop in cotiled diag - precompute num_tmem_alloc_cols 2026-05-24 00:07:22 +00:00
921decb516 D1.3: Fix cotiled diagnostic - use proper MMA construction 2026-05-24 00:06:50 +00:00
25747675cf D1.3: Add make_cotiled_copy diagnostic test 2026-05-24 00:05:48 +00:00
24bc318480 shit left dangling 2026-05-23 23:58:57 +00:00
1e5635b93f D1.3: Add SMEM-P coordinate diagnostic test 2026-05-23 23:23:05 +00:00
c507d0640c D1.3: Enhanced diagnostic - test QK C-fragment as source for make_tiled_copy_C 2026-05-23 22:24:15 +00:00
bf896c0894 D1.3: Skip fragment creation in diagnostic, just print layouts 2026-05-23 22:21:31 +00:00
0c435b3e51 D1.3: Fix diagnostic - use dummy ptr 0 for shape analysis 2026-05-23 22:20:16 +00:00
55caf8be38 D1.3: Fix sP allocation - p_smem_s.outer is already a layout 2026-05-23 22:19:11 +00:00
d1c600f599 D1.3: Fix layout diagnostic - compute c_major outside kernel 2026-05-23 22:17:54 +00:00
d3d0020b4e D1.3: Layout diagnostic v2 - run inside JIT-compiled kernel 2026-05-23 22:16:57 +00:00
ec8fd1474c D1.3: Fix layout diagnostic - remove JIT-dependent code 2026-05-23 22:15:47 +00:00
c3a7c30f20 D1.3: Layout diagnostic - print all QK C-fragment and PV A-operand shapes 2026-05-23 22:14:35 +00:00
2ced9d0da7 D5b: Fix reference computation - use logsumexp for stable LSE, fix o_unnorm definition 2026-05-23 21:43:04 +00:00
70763030c0 D5b: Use normalized O + LSE for merge (correct formula), always output LSE 2026-05-23 21:35:40 +00:00
28949da6e4 D5b: Clean up merge test - stable formula for both ref and kernel 2026-05-23 21:33:45 +00:00
9e1859827f D5b: Use reference per-row LSE for proper O normalization 2026-05-23 21:31:52 +00:00
48d37d652e D5b: Fix kernel_obj reference 2026-05-23 21:30:59 +00:00
caf89c65bf D5b: Fix syntax error 2026-05-23 21:30:00 +00:00
3dd9cd6a94 D5b: Debug reference formula mismatch, add numerically stable merge 2026-05-23 21:19:25 +00:00
98390df27e D5b: Python SWA+sink merge test
- Run FMHA twice (compressed KV + SWA KV, normalize=False)
- Merge with sink weights in Python
- Verify end-to-end correctness vs FP32 reference
2026-05-23 21:18:06 +00:00
c80f223d08 D5a: Add normalize flag + LSE output
- normalize=True (default): O = softmax(P) @ V (existing behavior)
- normalize=False: O = P @ V (un-normalized) + lse = log(row_sum) + row_max
- LSE tensor passed as optional parameter
- Test includes D5a normalize=False verification with LSE comparison
- Cleaned up SMEM-P debug prints and broken make_tiled_copy_C code
- hd=64 TMEM-P regression: cos 0.973 PASS
2026-05-23 21:10:40 +00:00
b13da6b7a0 diag: add 2-CTA check + fix LayoutEnum in MMA test 2026-05-23 08:45:26 +00:00
c34291843b fix: remove bad import in NVFP4 diag 2026-05-23 08:44:37 +00:00
538dbb0643 fix: use quantize_activation_nvfp4 in diag 2026-05-23 08:39:12 +00:00
e2f599e4af fix: use correct API for NVFP4-0 diag (sf_vec_size + mma_tiler_mn) 2026-05-23 08:38:19 +00:00
5572b74591 fix: use Sm100BlockScaledPersistentDenseGemmKernel in diag 2026-05-23 08:30:43 +00:00
6b1330ba47 fix: use randint+view for FP4/FP8 tensors in diag 2026-05-23 08:29:16 +00:00