]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
ggml-webgpu: address quantization precision and backend lifecycle managment (#21521)
authorChen Yuan <redacted>
Fri, 10 Apr 2026 17:52:01 +0000 (13:52 -0400)
committerGitHub <redacted>
Fri, 10 Apr 2026 17:52:01 +0000 (10:52 -0700)
commite4fed9d08de1d33ab51748880d38b62b9968dc2e
tree34dffa74bbd5dc8d6ac29ff592f9a35a936304b8
parent5dd102539b97b3cc92c503063a2a244b3c7d57bd
ggml-webgpu: address quantization precision and backend lifecycle managment (#21521)

* ggml(webgpu): fix the busy-polls in Emscripten  in the waitAny after #20618, and remove the busy webgpu log

* Merge with upstream

* Fix GET_ROWS packed integer NaN when using f16 as memory buffer in shader quants

* Update Unary wgsl EXP and EXPM1 for f16 stability

* Fix GET_ROWS IQ4_XS strcut for NaN f16 canonicalization

* Fix numerical percision for unary sqrt when working with f16

* Fix NaN canonicalization for packed integers using f16

* Update err threshold for binary div ops when using f16

* backend: Keep one Dawn/WebGPU instance alive for the lifetime of the static backend

* clean: uncomment existing code logs

* clean: clean the unncessary debug info

* Refactor and generalize dequant helpers

* Remove deprecated quant structs

* Refactor shader defines to reduce repetition

* Remove error override for F16 type

* fix: fix the accidential removal of the proper initialization of ctx

* clean: clean legacy and format code

* fix: did not modify tests ops

---------

Co-authored-by: Jeremy J. Hartmann <redacted>
ggml/src/ggml-webgpu/ggml-webgpu-shader-lib.hpp
ggml/src/ggml-webgpu/ggml-webgpu.cpp
ggml/src/ggml-webgpu/wgsl-shaders/common_decls.tmpl
ggml/src/ggml-webgpu/wgsl-shaders/get_rows.wgsl
ggml/src/ggml-webgpu/wgsl-shaders/mul_mat.wgsl
ggml/src/ggml-webgpu/wgsl-shaders/mul_mat_decls.tmpl
ggml/src/ggml-webgpu/wgsl-shaders/mul_mat_vec.wgsl
ggml/src/ggml-webgpu/wgsl-shaders/unary.wgsl