From 32b9f1f69d75896864174ebf989ccfb10f4e323b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20du=20Hamel?= Date: Tue, 8 Sep 2026 21:53:27 +0200 Subject: [PATCH] docs: reflect GGML_MAX_NAME value change in rpc docs (and in ggml_extend assert) --- docs/rpc.md | 14 +++++++------- src/core/ggml_extend.h | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/docs/rpc.md b/docs/rpc.md index 617a8b5a1..ea9edf1c3 100644 --- a/docs/rpc.md +++ b/docs/rpc.md @@ -57,7 +57,7 @@ The RPC server acts as the worker. You must explicitly enable the **backend** (t To find the correct flags for your system, refer to the official documentation for the [`llama.cpp`](https://github.com/ggml-org/llama.cpp/blob/master/docs/build.md) repository. -> **Crucial:** You must include the compiler flags required to satisfy the API compatibility with `stable-diffusion.cpp` (`-DGGML_MAX_NAME=128`). Without this flag, `GGML_MAX_NAME` will default to `64` for the server, and data transfers between the client and server will fail. Of course, `-DGGML_RPC` must also be enabled. +> **Crucial:** You must include the compiler flags required to satisfy the API compatibility with `stable-diffusion.cpp` (`-DGGML_MAX_NAME=160`). Without this flag, `GGML_MAX_NAME` will default to `64` for the server, and data transfers between the client and server will fail. Of course, `-DGGML_RPC` must also be enabled. > > I recommend disabling the `LLAMA_CURL` flag to avoid unnecessary dependencies, and disabling shared library builds to avoid potential conflicts. @@ -72,8 +72,8 @@ cmake .. -DGGML_RPC=ON \ -DGGML_VULKAN=ON \ # Ensure backend is enabled -DGGML_BUILD_SHARED_LIBS=OFF \ -DLLAMA_CURL=OFF \ - -DCMAKE_C_FLAGS=-DGGML_MAX_NAME=128 \ - -DCMAKE_CXX_FLAGS=-DGGML_MAX_NAME=128 + -DCMAKE_C_FLAGS=-DGGML_MAX_NAME=160 \ + -DCMAKE_CXX_FLAGS=-DGGML_MAX_NAME=160 cmake --build . --config Release --target rpc-server -j $(nproc) ``` @@ -86,8 +86,8 @@ cmake .. -DGGML_RPC=ON \ -DGGML_METAL=ON \ -DGGML_BUILD_SHARED_LIBS=OFF \ -DLLAMA_CURL=OFF \ - -DCMAKE_C_FLAGS=-DGGML_MAX_NAME=128 \ - -DCMAKE_CXX_FLAGS=-DGGML_MAX_NAME=128 + -DCMAKE_C_FLAGS=-DGGML_MAX_NAME=160 \ + -DCMAKE_CXX_FLAGS=-DGGML_MAX_NAME=160 cmake --build . --config Release --target rpc-server ``` @@ -101,8 +101,8 @@ cmake .. -G "Visual Studio 17 2022" -A x64 ` -DGGML_VULKAN=ON ` -DGGML_BUILD_SHARED_LIBS=OFF ` -DLLAMA_CURL=OFF ` - -DCMAKE_C_FLAGS=-DGGML_MAX_NAME=128 ` - -DCMAKE_CXX_FLAGS=-DGGML_MAX_NAME=128 + -DCMAKE_C_FLAGS=-DGGML_MAX_NAME=160 ` + -DCMAKE_CXX_FLAGS=-DGGML_MAX_NAME=160 cmake --build . --config Release --target rpc-server ``` diff --git a/src/core/ggml_extend.h b/src/core/ggml_extend.h index 4d5b1c897..585d4582c 100644 --- a/src/core/ggml_extend.h +++ b/src/core/ggml_extend.h @@ -9,7 +9,7 @@ #define EPS 1e-05f -static_assert(GGML_MAX_NAME >= 128, "GGML_MAX_NAME must be at least 128"); +static_assert(GGML_MAX_NAME >= 160, "GGML_MAX_NAME must be at least 160"); // n-mode tensor-matrix product // example: 2-mode product