Speed up Windows ARM64 Vulkan builds - #38
Draft
leehack wants to merge 1 commit into
Draft
Conversation
leehack
marked this pull request as ready for review
August 18, 2026 14:10
leehack
marked this pull request as draft
August 18, 2026 14:14
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
windows-2022with the x64-hosted Visual Studio Clang toolchain and Ninjaggml-vulkantarget with-Oswhile retaining Release ThinLTO; embedded SPIR-V is unchangedWhy
At the current b10453 baseline,
ggml-vulkan.cppaccounted for roughly 25 minutes of a 33m12s Windows ARM64 Vulkan source build under Clang-O3. Disabling IPO globally or only for the backend did not materially fix that bottleneck.The final
-Os+ Release IPO variant completed the full source build in 6m12s and the job in 7m34s. The generatedggml-vulkan.dllremained about 37 MiB, matching the original optimized package range.Validation
python3 -m unittest discover -s tools/tests -v— 3/3 passpython3 -m json.tool CMakePresets.json— passpython3 -m py_compile tools/build.py tools/tests/test_windows_build_config.py— passactionlint .github/workflows/validate_wrapper.yml— passllama_dart_speculative_need_embd*, verifiedggml-base.dll, KleidiAI, and fast-compile cache contract verifiedNegative/control experiments:
-O1without IPO: https://github.com/leehack/llamadart-native/actions/runs/32128688308 — 6m10s but ~52 MiB Vulkan DLL; rejected-Oswithout IPO: https://github.com/leehack/llamadart-native/actions/runs/32129550242 — 6m30s but ~51 MiB Vulkan DLL; rejectedPublication gate
Before publishing a release built with this path, Windows ARM64 Vulkan hardware must validate model load, generation correctness, and representative throughput. The change lowers optimization only for CPU-side Vulkan host code, so compile/package evidence cannot exclude a runtime performance regression.
Merging this build configuration does not publish artifacts; the native release workflow remains a separate approval boundary.
No
llamadartchange is required: artifact names, package layout, public headers, and exported ABI are unchanged.Tracked by #65.