KhronosGroup / KhronosGroup/Vulkan-Docs

Can vkCmdPipelineBarrier2KHR be used to perform queue family ownership transfers?

Open
#1,516 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
3.3k
Forks
549
Avg merge
5d 5h
Merged PRs (30d)
2

Description

The 1.2.177 spec says that `vkCmdPipelineBarrier` is used to define the release and acquire operations necessary for a queue family ownership transfer in [7.7.4. Queue Family Ownership Transfer](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#synchronization-queue-transfers). There is no mention of `vkCmdPipelineBarrier2KHR` in that section, and it states repeatedly that only `vkCmdPipelineBarrier` is suitable for this purpose, which would seem to imply that `vkCmdPipelineBarrier2KHR` is not.

However, the definitions of [`vkBufferMemoryBarrier2KHR`](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkBufferMemoryBarrier2KHR.html) and [`vkImageMemoryBarrier2KHR`](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkImageMemoryBarrier2KHR.html) state clearly that they can be used to define queue family ownership transfers. The only commands where these structures are used are in `synchronization2` commands for events and `vkCmdPipelineBarrier2KHR`; since the spec is clear in stating that events are not suitable for defining queue family ownership transfers, `vkCmdPipelineBarrier2KHR` would be the only means left to use them in this fashion. This would seem to imply that `vkCmdPipelineBarrier2KHR` _is_ suitable for performing queue family ownership transfers.

Which is correct?

Contributor guide

Open the contributing guide

Research direction

Compare the 1.2.177 Queue Family Ownership Transfer section with the VkBufferMemoryBarrier2KHR and VkImageMemoryBarrier2KHR definitions, and review where these structures are used by synchronization2 commands. Determine whether the specification is internally consistent about vkCmdPipelineBarrier2KHR; done means the relevant specification wording and command guidance clearly resolve the question.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.