vulkan: change graph_compute to be async and enable get_tensor_async#17158
Merged
0cc4m merged 4 commits intoggml-org:masterfrom Nov 15, 2025
Merged
vulkan: change graph_compute to be async and enable get_tensor_async#171580cc4m merged 4 commits intoggml-org:masterfrom
0cc4m merged 4 commits intoggml-org:masterfrom
Conversation
This allows some additional CPU/GPU overlap for large pp workloads. Also seems to help a bit for token gen, maybe getting rid of a small bubble between graph_compute and get_tensor. Async set and copy functions seem to be very rarely used, so I didn't enable them because I didn't have a good way to test them. The async commands need to be ordered against each other, so put them all on the compute queue. The non-async commands still use the transfer queue. The fence for graph_compute/get_tensor_async is submitted and waited on in ggml_vk_synchronize.
a66edc0 to
924df57
Compare
0cc4m
approved these changes
Nov 15, 2025
Collaborator
0cc4m
left a comment
There was a problem hiding this comment.
I can't see any performance differences, but no issues either.
Commit 38eaf32 makes my intel DG1 vomit gibberish. Will you be able to have another look? Thanks. |
Collaborator
|
Are you sure it's not just #17106? |
Collaborator
Author
|
Please file an issue for this and share more details. What were you running? Does test-backend-ops pass? |
Thanks. I filed an issue here #17302 |
Anico2
added a commit
to Anico2/llama.cpp
that referenced
this pull request
Jan 15, 2026
…gml-org#17158) * vulkan: change graph_compute to be async and enable get_tensor_async This allows some additional CPU/GPU overlap for large pp workloads. Also seems to help a bit for token gen, maybe getting rid of a small bubble between graph_compute and get_tensor. Async set and copy functions seem to be very rarely used, so I didn't enable them because I didn't have a good way to test them. The async commands need to be ordered against each other, so put them all on the compute queue. The non-async commands still use the transfer queue. The fence for graph_compute/get_tensor_async is submitted and waited on in ggml_vk_synchronize. * fix thread safety errors * teardown context cleanly * Handle async read to non-pinned dst
blime4
referenced
this pull request
in blime4/llama.cpp
Feb 5, 2026
…(#17158) * vulkan: change graph_compute to be async and enable get_tensor_async This allows some additional CPU/GPU overlap for large pp workloads. Also seems to help a bit for token gen, maybe getting rid of a small bubble between graph_compute and get_tensor. Async set and copy functions seem to be very rarely used, so I didn't enable them because I didn't have a good way to test them. The async commands need to be ordered against each other, so put them all on the compute queue. The non-async commands still use the transfer queue. The fence for graph_compute/get_tensor_async is submitted and waited on in ggml_vk_synchronize. * fix thread safety errors * teardown context cleanly * Handle async read to non-pinned dst
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.
This allows some additional CPU/GPU overlap for large pp workloads. Also seems to help a bit for token gen, maybe getting rid of a small bubble between graph_compute and get_tensor.
Async set and copy functions seem to be very rarely used, so I didn't enable them because I didn't have a good way to test them.
The async commands need to be ordered against each other, so put them all on the compute queue. The non-async commands still use the transfer queue.
The fence for graph_compute/get_tensor_async is submitted and waited on in ggml_vk_synchronize.
See #17033 (comment).