From 6734e77662dac4ab24f4b5cb5cc39609ea3d2b13 Mon Sep 17 00:00:00 2001 From: ddh0 Date: Thu, 12 Feb 2026 18:22:14 -0600 Subject: [PATCH] don't throw by pointer; unify MiB formatting --- src/llama-quant.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/llama-quant.cpp b/src/llama-quant.cpp index dd81b310d8..c9b7e5c7ce 100644 --- a/src/llama-quant.cpp +++ b/src/llama-quant.cpp @@ -873,7 +873,7 @@ static void llama_model_quantize_impl(const std::string & fname_inp, const std:: " - target type: %s\n" "============================================================================\n\n", name.c_str(), ggml_type_name(target_type)); - throw new std::runtime_error("this quantization requires an imatrix!"); + throw std::runtime_error("this quantization requires an imatrix!"); } } } @@ -981,7 +981,7 @@ static void llama_model_quantize_impl(const std::string & fname_inp, const std:: // the --dry-run option calculates the final quantization size without quantizting if (do_quantize) { new_size = ggml_nrows(tensor) * ggml_row_size(new_type, tensor->ne[0]); - LLAMA_LOG_INFO("size = %8.2f MiB -> %8.2f MiB (%s)\n", + LLAMA_LOG_INFO("size = %8.3f MiB -> %8.3f MiB (%s)\n", tensor_size/1024.0/1024.0, new_size/1024.0/1024.0, ggml_type_name(new_type)); @@ -1097,7 +1097,7 @@ static void llama_model_quantize_impl(const std::string & fname_inp, const std:: } #endif } - LLAMA_LOG_INFO("size = %8.2f MiB -> %8.2f MiB\n", tensor_size/1024.0/1024.0, new_size/1024.0/1024.0); + LLAMA_LOG_INFO("size = %8.3f MiB -> %8.3f MiB\n", tensor_size/1024.0/1024.0, new_size/1024.0/1024.0); } total_size_org += tensor_size; total_size_new += new_size;