]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
model : don't crash on unsupported architecture (#22742)
authorGilad S. <redacted>
Wed, 6 May 2026 16:51:21 +0000 (11:51 -0500)
committerGitHub <redacted>
Wed, 6 May 2026 16:51:21 +0000 (18:51 +0200)
* model: don't crash on unsupported architecture

* Update src/llama-model.cpp

Co-authored-by: Sigbjørn Skjæret <redacted>
---------

Co-authored-by: Sigbjørn Skjæret <redacted>
src/llama-model.cpp

index 9a5802e3242d570b9254c8e9e84ea932aaea854f..67d648d3bab92c9340a0197fe88c2c59fb430a64 100644 (file)
@@ -285,7 +285,7 @@ static llama_model * llama_model_mapping(llm_arch arch, const llama_model_params
         case LLM_ARCH_STEP35:
             return new llama_model_step35(params);
         default:
-            GGML_ABORT("unimplemented model class");
+            throw std::runtime_error(std::string("unsupported model architecture: '") + llm_arch_name(arch) + "'");
     }
 
 }