diff --git a/tests/unit/test_fmha_smem_p.cu b/tests/unit/test_fmha_smem_p.cu index 4c49fffe..09d1ba87 100644 --- a/tests/unit/test_fmha_smem_p.cu +++ b/tests/unit/test_fmha_smem_p.cu @@ -69,7 +69,8 @@ test_fmha_smem_p(const bf16_t* __restrict__ q, const bf16_t* __restrict__ k, __syncthreads(); uint32_t tb = *sTmemBase; - // ===== STEP 1: QK GEMM ===== + // ===== STEP 1: QK GEMM — SKIPPED ===== + /* { uint64_t dq = make_umma_desc_kmajor_none(__cvta_generic_to_shared(sQ0), BLOCK_MN); uint64_t dk = make_umma_desc_kmajor_none(__cvta_generic_to_shared(sK0), BLOCK_MN); @@ -80,44 +81,19 @@ test_fmha_smem_p(const bf16_t* __restrict__ q, const bf16_t* __restrict__ k, __syncthreads(); } } + */ - // ===== STEP 2: Softmax — read S from TMEM, write P to SMEM ===== - if (wid == 0) { - float s_vals[SK], row_max = -INFINITY; - for (int n = 0; n < SK / 8; n++) { - float tmp[8]; - asm volatile("tcgen05.ld.sync.aligned.32x32b.x8.b32 {%0,%1,%2,%3,%4,%5,%6,%7},[%8];" - : "=f"(tmp[0]),"=f"(tmp[1]),"=f"(tmp[2]),"=f"(tmp[3]), - "=f"(tmp[4]),"=f"(tmp[5]),"=f"(tmp[6]),"=f"(tmp[7]) - : "r"(tb + n*8)); - asm volatile("tcgen05.wait::ld.sync.aligned;"); - if (lane == 0) for (int c=0;c<8;c++) { - s_vals[n*8+c] = tmp[c] * scale; - row_max = fmaxf(row_max, tmp[c] * scale); - } - } - row_max = wmax(row_max); - float row_sum = 0.0f; - if (lane == 0) for (int j=0;j