Skip to content

Conversation

@jeffbolznv
Copy link
Collaborator

The std::map pipeline_flash_attn_f32_f16 could be searched and inserted at the same time, which needs to hold the lock. To be safe, hold the lock for all of ggml_vk_load_shaders.

See #16826 (comment)

The std::map pipeline_flash_attn_f32_f16 could be searched and inserted at the
same time, which needs to hold the lock. To be safe, hold the lock for all of
ggml_vk_load_shaders.
@jeffbolznv jeffbolznv requested a review from 0cc4m as a code owner November 5, 2025 15:46
@jeffbolznv
Copy link
Collaborator Author

@Acly please let me know if this fixes it for you. It does on my system.

@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 Nov 5, 2025
Copy link
Collaborator

@Acly Acly left a comment

Choose a reason for hiding this comment

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

Fix looks good, I don't see crashes anymore with this.

Maybe we want a safer solution in the long run than scattering mutex-locks and atomics about in hopefully all the right places?

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.

2 participants