diff --git a/src/core/verify.cpp b/src/core/verify.cpp index d760698e..64ffc92a 100644 --- a/src/core/verify.cpp +++ b/src/core/verify.cpp @@ -1319,7 +1319,7 @@ bool Verifier::record_window(int T, cudaStream_t cs, std::string& err) { // output), and qkv is recorded before the branch's launch, so its grid is dispatched first and the // conv / recurrence that wait for it start sooner (z is read only after the recurrence) const bool g_il = g_mmvq_il() && strata::kernels::native_mmvq_il_supported(wg->native_type, n, (int) ZV); - if (g_il && !il_ready) { + if (g_il && !il_ready && n >= 2) { strata::kernels::native_q8_1_interleave(xq_, xil_, (int) N, n, cs); il_ready = true; } @@ -1597,7 +1597,7 @@ bool Verifier::record_window(int T, cudaStream_t cs, std::string& err) { if (cudaEventRecord(mjoin_, side_) != cudaSuccess) { err = "verify: the indexer's branch could not join"; return false; } } if (side_proj) { // the queries beside the keys and values (fork b063c13) - if (q_il && !il_ready) { // the copy before the fork (mm(wk) / mm(wv) on cs reuse it) + if (q_il && !il_ready && n >= 2) { // the copy before the fork (mm(wk) / mm(wv) on cs reuse it) strata::kernels::native_q8_1_interleave(xq_, xil_, (int) N, n, cs); il_ready = true; }