diff options
author | Rickard Hallerbäck <rickard.hallerback@gmail.com> | 2023-09-27 17:48:33 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-27 18:48:33 +0300 |
commit | dc6897404e141c74cbbf8030ecfebd74e1815411 (patch) | |
tree | c36354fd18ce45ff12fbf8b7ebfc5004834a40dc /ggml.h | |
parent | 527e57cfd8a9a26bf622c0510c21c2508a24be26 (diff) |
metal : reusing llama.cpp logging (#3152)
* metal : reusing llama.cpp logging
* cmake : build fix
* metal : logging callback
* metal : logging va_args memory fix
* metal : minor cleanup
* metal : setting function like logging macro to capital letters
* llama.cpp : trailing whitespace fix
* ggml : log level enum used by llama
* Makefile : cleanup ggml-metal recipe
* ggml : ggml_log_callback typedef
* ggml : minor
---------
Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>
Diffstat (limited to 'ggml.h')
-rw-r--r-- | ggml.h | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -445,6 +445,12 @@ extern "C" { GGML_OBJECT_WORK_BUFFER }; + enum ggml_log_level { + GGML_LOG_LEVEL_ERROR = 2, + GGML_LOG_LEVEL_WARN = 3, + GGML_LOG_LEVEL_INFO = 4 + }; + // ggml object struct ggml_object { size_t offs; @@ -1691,6 +1697,7 @@ extern "C" { }; typedef void (*ggml_opt_callback)(void * data, float * sched); + typedef void (*ggml_log_callback)(enum ggml_log_level level, const char * text, void * user_data); // optimization parameters // |