-
Notifications
You must be signed in to change notification settings - Fork 199
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test cl_khr_command_buffer_mutable_dispatch #1481
Comments
Now that the oneAPI Construction Kit is open source, i'll highlight that it has unit tests for this extension that could be used for inspiration to fill in the CTS gaps, although it focuses on kernel argument update. https://github.com/codeplaysoftware/oneapi-construction-kit/tree/main/source/cl/test/UnitCL/source/cl_khr_command_buffer_mutable_dispatch In particular, to the plan above:
|
Noting that the mutable dispatch asserts from PR KhronosGroup/OpenCL-Docs#992 also need CTS testing as described in #1897 |
hello @EwanC, I am begining my work on finishing this issue and after initial review I am a bit concerned about points |
Hi @shajder, that's great you are able to pick this up again. That's a good point about out-of-order queues, device support for that is conditional on Regarding getting rid of the out-of-order queues, using an out-of-order queue is a valid use of the extension so I'm a bit reluctant to reduce coverage from a valid test. |
make sense, I will refactor code to handle all mentioned cases
understood, I will keep out-of-order test cases along with new in-order ones |
@EwanC one more concern, in tests ... Determines whether the global_work_offset of kernel execution can be modified after recording. If set, the global_work_offset of the kernel execution can be changed with clUpdateMutableCommandsKHR using the cl_mutable_dispatch_config_khr field of the mutable_config parameter. Otherwise, the global_work_offset cannot be modified. |
Another good question, there is the language in the spec for
Therefore I think the tests are correct by that default wording since |
According to KhronosGroup#1481 issue description, point 2.1
According to KhronosGroup#1481 issue description, point 2.1
-cross queue simultaneous use -in-order queue with simultaneous use According to issue description KhronosGroup#1481
Added #1912 along with two test cases: |
According to issue description KhronosGroup#1481
According to issue description KhronosGroup#1481
According to issue description KhronosGroup#1481
* Added new tests for simultaneous use with mutable dispatch -cross queue simultaneous use -in-order queue with simultaneous use According to issue description #1481 * Several corrections applied: -reordered Skip conditions to check valid simultaneous_use_support flag -removed unnecessary SetUpKernel call -initialize kernel and memory buffers from BasicCommandBufferTest instead BasicMutableCommandBufferTest * Corrections for command buffer creation to request simultaneous property
* Added test to cover overwritten update of mutable parameters According to issue description #1481 * cosmetic corrections * Corrections due to code review
* Added test to cover iterative mutable argument update According to issue description #1481 * cosmetic correction * clang format fix * Corrections due to code review
Closing this issue as all the items in the test plan have been covered with a merged CTS PR. New issues can be open to track any future CTS gaps in cl_khr_command_buffer_mutable_dispatch |
Test plan for cl_khr_command_buffer_mutable_dispatch breaking down the areas which need to be covered.
1 Device Info Query
Verify the following queries can be performed successfully and return
defined values:
CL_DEVICE_MUTABLE_DISPATCH_CAPABILITIES_KHR
EDIT - Done in #1651
2 Mutable-commands
2.1 Mutable-dispatch
For each property in
cl_mutable_dispatch_properties_khr
reported by device query.CL_COMMAND_BUFFER_MUTABLE_KHR
clCommandNDRangeKernelKHR
returning acl_mutable_command_khr
objectCL_MUTABLE_DISPATCH_GLOBAL_OFFSET_KHR
Add global offset tests for cl_khr_command_buffer_mutable_dispatch. #1743CL_MUTABLE_DISPATCH_GLOBAL_SIZE_KHR
Add global size tests for cl_khr_command_buffer_mutable_dispatch. #1744CL_MUTABLE_DISPATCH_LOCAL_SIZE_KHR
Add local size tests for cl_khr_command_buffer_mutable_dispatch. #1745CL_MUTABLE_DISPATCH_ARGUMENTS_KHR
for normal arguments and SVM. Checking variants of:CL_MUTABLE_DISPATCH_EXEC_INFO_KHR
Part of SVM test in Add arguments tests for cl_khr_command_buffer_mutable_dispatch. #17492.1.1 Multiple updates
clUpdateMutableCommandsKHR()
in a way which updates more than one command-handle in the same call. Added new test to cover multiple commands dispatch in one enqueued update #1919clUpdateMutableCommandsKHR()
several times on the same command-handle and make sure that the most recent value persists. Added test to cover overwritten update of mutable parameters #1922clUpdateMutableCommandsKHR()
being called multiple times on the same command before an enqueue, but with different arguments. Verify that all the combined updates are made correctly. Added test to cover iterative mutable argument update #19252.1.2 Simultaneous use
2.1.3 cross-queue simultaneous-use
EDIT: #1912
Test updating mutable-dispatch objects of a command-buffer while a previous instance of the command-buffer is in flight to a different queue. See 1.3.3 from the cl_khr_comand_buffer test plan, but changing one of the command-buffer enqueues to the original queue.
2.2 clGetMutableCommandInfoKHR
Test each of the queries in
clGetMutableCommandInfoKHR()
:CL_MUTABLE_COMMAND_COMMAND_QUEUE_KHR
CL_MUTABLE_COMMAND_COMMAND_BUFFER_KHR
CL_MUTABLE_DISPATCH_PROPERTIES_ARRAY_KHR
CL_MUTABLE_DISPATCH_KERNEL_KHR
CL_MUTABLE_DISPATCH_DIMENSIONS_KHR
CL_MUTABLE_DISPATCH_GLOBAL_WORK_OFFSET_KHR
CL_MUTABLE_DISPATCH_GLOBAL_WORK_SIZE_KHR
CL_MUTABLE_DISPATCH_LOCAL_WORK_SIZE_KHR
CL_MUTABLE_COMMAND_COMMAND_TYPE_KHR
Edit - Done in #1651
The text was updated successfully, but these errors were encountered: