### Git commit 667d72846c06b2cf4f7c8a4265e210991a49706b ### Operating systems Linux ### GGML backends Vulkan ### Problem description & steps to reproduce I'm compiling the `llamacpp` openSUSE package and found that the `libggml-vulkan.so` differs in every build. My analysis points to https://github.com/ggerganov/llama.cpp/blob/bd38dde/ggml/src/ggml-vulkan/vulkan-shaders/vulkan-shaders-gen.cpp#L502 as the place where some sorting is missing to provide deterministic output. ### First Bad Commit _No response_ ### Compile command ```shell we build with cmake - see https://github.com/bmwiedemann/openSUSE/blob/0da890b/packages/l/llamacpp/llamacpp.spec#L123 for details. ``` ### Relevant log output ```shell Generated source-code varied (randomly) thusly: /home/abuild/rpmbuild/BUILD.unsorted/llamacpp-4501/build/ggml/src/ggml-vulkan/ggml-vulkan-shaders.cpp @@ -1,8 +1,892 @@ #include "ggml-vulkan-shaders.hpp" -unsigned char matmul_f16_f32_aligned_fp32_data[10276] = { +unsigned char matmul_q4_1_f16_fp32_data[10564] = { ... ```
Activity
jeffbolznv commentedon Jan 20, 2025
Hi, please try #11315
vulkan: sort shaders for more deterministic binary (#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
Merge vulkan code from mainline up to commit of 6/28/2025 (ggml-org#563)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)
vulkan: sort shaders for more deterministic binary (ggml-org#11315)