diff --git a/tests/hip/prefill_mmq_parity.cpp b/tests/hip/prefill_mmq_parity.cpp index 00946e88..c477d5b3 100644 --- a/tests/hip/prefill_mmq_parity.cpp +++ b/tests/hip/prefill_mmq_parity.cpp @@ -137,7 +137,10 @@ Metrics run_product(Context & ctx, hipStream_t stream, const std::string & name, hip_check(hipMemcpy(ddst.p, dst_ids.data(), dst_ids.size() * sizeof(int32_t), hipMemcpyHostToDevice), "copy dst ids"); hip_check(hipMemcpy(dbounds.p, bounds.data(), bounds.size() * sizeof(int32_t), hipMemcpyHostToDevice), "copy bounds"); hip_check(hipMemcpy(dw.p, w.data(), w.size(), hipMemcpyHostToDevice), "copy weights and zero tail"); - hip_check(hipMemset(dy.p, 0xff, (size_t) rows * (size_t) out_rows * sizeof(float)), "initialize output sentinel"); + // On the product's stream: a plain hipMemset runs on the null stream, which a non-blocking stream does not wait + // for - on a Radeon 8060S (gfx1151, Windows) it landed after the MMQ kernel and left only the sentinel + hip_check(hipMemsetAsync(dy.p, 0xff, (size_t) rows * (size_t) out_rows * sizeof(float), stream), + "initialize output sentinel"); quantize(dx.as(), dsrc.as(), dxq.p, (int) type, cols, cols, rows, (void *) stream); const int max_rows = *std::max_element(counts.begin(), counts.end());