]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
vulkan: Hybrid waitForFences/getFenceStatus to reduce fence latency (#12630)
authorJeff Bolz <redacted>
Fri, 4 Apr 2025 05:54:35 +0000 (00:54 -0500)
committerGitHub <redacted>
Fri, 4 Apr 2025 05:54:35 +0000 (07:54 +0200)
commit74d4f5b041ad837153b0e90fc864b8290e01d8d5
tree9ae6f9dd0984b780c942ccf510e9cd5fcee9e724
parent35e592eb30832187412360912ab8f2f5b7984df1
vulkan: Hybrid waitForFences/getFenceStatus to reduce fence latency (#12630)

There seems to be a bubble waking up from waitForFences, which costs a few
percent performance and also increased variance in performance. This change
inserts an "almost_ready" fence when the graph is about 80% complete and we
waitForFences for the almost_ready fence and then spin (with _mm_pauses) waiting
for the final fence to be signaled.
ggml/src/ggml-vulkan/ggml-vulkan.cpp