Skip to content

vulkan: Read nodes_per_submit from GGML_VK_NODES_PER_SUBMIT env - #24240

Closed
konradmb wants to merge 1 commit into
ggml-org:masterfrom
konradmb:vk-nodes-per-submit
Closed

vulkan: Read nodes_per_submit from GGML_VK_NODES_PER_SUBMIT env#24240
konradmb wants to merge 1 commit into
ggml-org:masterfrom
konradmb:vk-nodes-per-submit

Conversation

@konradmb

@konradmb konradmb commented Jun 6, 2026

Copy link
Copy Markdown
Contributor

Overview

Allow setting a custom nodes_per_submit value.

Additional information

Workaround for #21724

Requirements

  • I have read and agree with the contributing guidelines ✔️
  • AI usage disclosure: Yes 😩 (Qwen 3.6 suggested to use lambda to avoid race and re-reading)

@konradmb
konradmb requested a review from a team as a code owner June 6, 2026 18:52
@github-actions github-actions Bot added Vulkan Issues specific to the Vulkan backend ggml changes relating to the ggml tensor library for machine learning labels Jun 6, 2026
@ggml-gh-bot

ggml-gh-bot Bot commented Jun 6, 2026

Copy link
Copy Markdown

Hi @konradmb, thanks for your contribution!

Per our contribution guidelines, the automated PR checker found the following issue(s) that need your attention:

  • Multiple open PRs from a new contributor: We limit new contributors (those without a previously merged PR) to 1 open PR at a time. You currently have 2 open PRs.

Please note that maintainers reserve the right to make final decisions on PRs. If you believe there is a mistake, please comment below.

@konradmb
konradmb force-pushed the vk-nodes-per-submit branch from c01c19c to 2a79a51 Compare June 7, 2026 14:35
static int nodes_per_submit = []() {
const char* env = getenv("GGML_VK_NODES_PER_SUBMIT");
return env ? atoi(env) : 100;
}();

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would have to become a vk_device parameter, you cannot read the environment variable in the graph_compute function.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I'll try. Do you have any examples of how similar features are implemented?
Should I add a new int to vk_device_struct and set it somewhere else from env var?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, exactly. Look at other flags/values there, like async_use_transfer_queue.

@wbruna

wbruna commented Jun 21, 2026

Copy link
Copy Markdown
Contributor

@konradmb : I'm sorry, but this PR is taking too long; I've given it a try myself with #24872 .

@konradmb

Copy link
Copy Markdown
Contributor Author

@wbruna Sure, great! Closing this one.

@konradmb konradmb closed this Jun 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ggml changes relating to the ggml tensor library for machine learning Vulkan Issues specific to the Vulkan backend

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants