From a40b01618b9351e2c44652f76599d815d882988f Mon Sep 17 00:00:00 2001 From: Jakub Sujak Date: Wed, 11 Dec 2024 10:13:01 +0000 Subject: [PATCH] Fix memory leak in F16 example Signed-off-by: Jakub Sujak --- .../matmul_clamp_f16_f16_f16p/matmul_clamp_f16_f16_f16p.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/examples/matmul_clamp_f16_f16_f16p/matmul_clamp_f16_f16_f16p.cpp b/examples/matmul_clamp_f16_f16_f16p/matmul_clamp_f16_f16_f16p.cpp index 9cdb053c..0baee907 100644 --- a/examples/matmul_clamp_f16_f16_f16p/matmul_clamp_f16_f16_f16p.cpp +++ b/examples/matmul_clamp_f16_f16_f16p/matmul_clamp_f16_f16_f16p.cpp @@ -104,6 +104,8 @@ bool is_output_correct( } // namespace int main() { + int ret = 0; + // Parameters of the matrix multiplication. Change these values to see how the micro-kernels operate on different // sized matrices const size_t M = 6; // Rows of LHS and DST matrices @@ -214,7 +216,7 @@ int main() { std::cout << "- Performance: " << time_matmul.count() << "ns\n"; } else { std::cout << "- Status: FAILED\n"; - return 1; + ret = 1; } //----------- END MICRO-KERNELS TESTS @@ -228,6 +230,6 @@ int main() { delete[] dst; delete[] dst_ref; - return 0; + return ret; } #endif // Architectural features check. -- GitLab