From 6fddb574dfdd1b34e3b3034349e9f054610aaea0 Mon Sep 17 00:00:00 2001 From: Herman Semenov Date: Fri, 22 Dec 2023 12:16:50 +0300 Subject: [PATCH] ggml: add comment with link to discussion suspicious function param --- ggml.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ggml.c b/ggml.c index f92292b39..8eb7db26a 100644 --- a/ggml.c +++ b/ggml.c @@ -14755,6 +14755,8 @@ static void ggml_compute_backward(struct ggml_context * ctx, struct ggml_tensor const int n_past = ((int32_t *) tensor->op_params)[0]; src0->grad = ggml_add_or_set(ctx, src0->grad, + /* ggml_diag_mask_inf_impl() shouldn't be here */ + /* ref: https://github.com/ggerganov/llama.cpp/pull/4203#discussion_r1412377992 */ ggml_diag_mask_zero_impl(ctx, tensor->grad, n_past, false), zero_table); }