Commit c21284cdf for llama.cpp
commit c21284cdf5fd833b90ac1f824cdf8065e2700dc4
Author: leejet <leejet714@gmail.com>
Date: Mon Sep 21 22:25:44 2026 +0800
ggml : fix dimension and stride truncation in ggml_permute (#29227)
diff --git a/ggml/src/ggml.c b/ggml/src/ggml.c
index 175281409..a286083b9 100644
--- a/ggml/src/ggml.c
+++ b/ggml/src/ggml.c
@@ -3897,8 +3897,8 @@ struct ggml_tensor * ggml_permute(
struct ggml_tensor * result = ggml_view_tensor(ctx, a);
ggml_format_name(result, "%s (permuted)", a->name);
- int ne[GGML_MAX_DIMS];
- int nb[GGML_MAX_DIMS];
+ int64_t ne[GGML_MAX_DIMS];
+ size_t nb[GGML_MAX_DIMS];
ne[axis0] = a->ne[0];
ne[axis1] = a->ne[1];