From 686d6d4227b42412e6eec3cce0cef995d819d4a4 Mon Sep 17 00:00:00 2001 From: luoyu-intel Date: Fri, 3 Nov 2023 16:16:53 +0800 Subject: [PATCH] fix benchmark error --- onnxruntime/test/mlas/bench/bench_q4gemm.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/onnxruntime/test/mlas/bench/bench_q4gemm.cpp b/onnxruntime/test/mlas/bench/bench_q4gemm.cpp index caf2eafddc396..fc5d05d1f35db 100644 --- a/onnxruntime/test/mlas/bench/bench_q4gemm.cpp +++ b/onnxruntime/test/mlas/bench/bench_q4gemm.cpp @@ -86,11 +86,11 @@ void Q4GEMM_Jblas(benchmark::State& state, int block_size, bool is_asym, MLAS_CO params1.ldc = N; params1.B = B1_packed.data(); params1.OutputProcessor = nullptr; - - MlasJblasQ4GemmBatch(M, N, K, 1, ¶ms1, tp.get()); + std::vector workspace(size_t(M) * K * 4); + MlasJblasQ4GemmBatch(M, N, K, 1, ¶ms1, workspace.data(), tp.get()); for (auto _ : state) { - MlasJblasQ4GemmBatch(M, N, K, 1, ¶ms1, tp.get()); + MlasJblasQ4GemmBatch(M, N, K, 1, ¶ms1, workspace.data(), tp.get()); } }