]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
mmap: Fix Windows handle lifetime (#19598)
authorGeorge <redacted>
Sat, 14 Feb 2026 08:05:12 +0000 (10:05 +0200)
committerGitHub <redacted>
Sat, 14 Feb 2026 08:05:12 +0000 (10:05 +0200)
commiteb145c0753e702d74447f427f7233d519ad1f8e6
treefdec2ce7bcbc31560a4866a8f3f771cc015aca2e
parent6e473fb384c21126ba3f1d5b5ce81ccbb17d465a
mmap: Fix Windows handle lifetime (#19598)

* ggml: added cleanups in ggml_quantize_free
Add missing cleanup calls for IQ2_S, IQ1_M quantization types and IQ3XS with 512 blocks during quantization cleanup.

* mmap: Fix Windows handle lifetime
Move hMapping from local variable to member variable so it stays alive for the entire lifetime of the mapping.
The file mapping handle must remain valid until UnmapViewOfFile is called.
Fixes cleanup order in destructor.

* Update llama-mmap.cpp

* Update llama-mmap.cpp

Remove trailing whitespace from line 567
src/llama-mmap.cpp