diff --git a/common/common.cpp b/common/common.cpp index d84d57ac9..3d54bd600 100644 --- a/common/common.cpp +++ b/common/common.cpp @@ -402,10 +402,11 @@ void common_params_print_info(const common_params & params, bool print_devices) #endif COM_TRC("%s: build %d (%s) with %s for %s%s\n", __func__, llama_build_number(), llama_commit(), llama_compiler(), llama_build_target(), build_type); - COM_INF("%s: verbosity = %d (adjust with the `-lv N` CLI arg)\n", __func__, common_log_get_verbosity_thold()); + const int verbosity = common_log_get_verbosity_thold(); + COM_INF("%s: verbosity = %d (adjust with the `-lv N` CLI arg)\n", __func__, verbosity); // device enumeration creates a primary context on CUDA backends, skip it when the caller does not own any device - if (print_devices) { + if (print_devices && verbosity >= LOG_LEVEL_TRACE) { COM_TRC("%s", "device_info:\n"); for (size_t i = 0; i < ggml_backend_dev_count(); ++i) { auto * dev = ggml_backend_dev_get(i);