Skip to content

Add simultaneous update capability#1466

Open
joselopeqti wants to merge 2 commits intoKhronosGroup:mainfrom
joselopeqti:simultaneous_update
Open

Add simultaneous update capability#1466
joselopeqti wants to merge 2 commits intoKhronosGroup:mainfrom
joselopeqti:simultaneous_update

Conversation

@joselopeqti
Copy link
Contributor

This PR addresses #1465.
It follows a similar pattern to the one used for simultaneous update #1411.

It adds the CL_COMMAND_BUFFER_CAPABILITY_SIMULTANEOUS_UPDATE_KHR capability, which allows developers to query if the implementation supports updating a command-buffer while an instance of the same is being ran.
If the capability is not supported, applications must wait for all previous submissions of the command-buffer to be finished before calling clUpdateMutableCommandsKHR.

It also fixes a wrong ifdef that was checking for cl_khr_command_buffer_multi_device instead of cl_khr_command_buffer_mutable_dispatch.

@bashbaug bashbaug added the cl_khr_command_buffer Relating to the command-buffer family of extension label Oct 14, 2025
@EwanC
Copy link
Contributor

EwanC commented Oct 28, 2025

Thanks for opening this, it's important to clarify to users if this is allowed, as it's an important use case to enable.

The current CTS test for non simultaneous-use workflow uses simultaneous-update behaviour by calling update without a blocking wait on the previous command-buffer enqueue. So all cl_khr_command_buffer_mutable_dispatch implementations that currently run and pass the mutable_dispatch_in_order/mutable_dispatch_out_of_order/mutable_dispatch_cross_queue tests should already support this behavior.

It would be interesting if that's been painful for any vendors and we should have this optional capability for simultaneous-update, or we can just make simultaneous-update required functionality for the extension and better specify that it is allowed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cl_khr_command_buffer Relating to the command-buffer family of extension

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants