vulkan: allow graph_optimize for prompt processing workloads#17475
Merged
0cc4m merged 1 commit intoggml-org:masterfrom Nov 26, 2025
Merged
vulkan: allow graph_optimize for prompt processing workloads#174750cc4m merged 1 commit intoggml-org:masterfrom
0cc4m merged 1 commit intoggml-org:masterfrom
Conversation
ggerganov
approved these changes
Nov 24, 2025
Collaborator
|
I've found one case where this change reduces performance, on this model on RTX 3090 with coopmat2. Other models show small improvements. Do you see this on your hardware? Master:
PR:
|
Collaborator
Author
|
Yes, I get a couple percent slowdown on this model on 5090 (less on 4070): I ran with ENABLE_SYNC_LOGGING before/after, and the number of syncs has decreased by 11%. The topk_moe fusion is still working. It looks like the multi-add might be getting split up, and maybe that's responsible for the slowdown? |
Collaborator
Author
|
I tried grouping the adds but it didn't help. I don't see anything obviously bad about the order it's generating. Maybe this model is just unlucky? |
Collaborator
|
Maybe. Not great, but good improvements for the rest, so it's okay. |
0cc4m
approved these changes
Nov 26, 2025
Anico2
added a commit
to Anico2/llama.cpp
that referenced
this pull request
Jan 15, 2026
blime4
pushed a commit
to blime4/llama.cpp
that referenced
this pull request
Feb 5, 2026
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.
See #17276 (comment).
When I first implemented this, I saw slowdowns in prompt processing when reordering the graph. But I've retested and now see a slight improvement. Not sure what has changed, maybe more fusions helps (though not all are enabled when nrows>1).