]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
llama : fix build_ffn without gate (#13336)
authorXuan-Son Nguyen <redacted>
Tue, 6 May 2025 12:25:40 +0000 (14:25 +0200)
committerGitHub <redacted>
Tue, 6 May 2025 12:25:40 +0000 (14:25 +0200)
* llama : fix build_ffn without gate

* fix build on windows

* Revert "fix build on windows"

This reverts commit fc420d3c7eef3481d3d2f313fef2757cb33a7c56.

src/llama-graph.cpp

index 0da4e7d2b0547c3cf3e13972bbdae55401efbfef..0b004a8ba6622f0f3eb99dfd49cfe7806e8bdfc7 100644 (file)
@@ -782,7 +782,7 @@ ggml_tensor * llm_graph_context::build_ffn(
             } break;
     }
 
-    if (type_gate == LLM_FFN_PAR) {
+    if (gate && type_gate == LLM_FFN_PAR) {
         cur = ggml_mul(ctx0, cur, tmp);
         cb(cur, "ffn_gate_par", il);
     }