Add tests for simultaneous use of secondary command buffer
authorTobin Ehlis <tobine@google.com>
Wed, 31 Aug 2016 18:49:07 +0000 (12:49 -0600)
committerTobin Ehlis <tobine@google.com>
Tue, 6 Sep 2016 22:53:35 +0000 (16:53 -0600)
commit5125b961903b5822c8fcd8e6d154736bac843835
treede784bdab45a8561f1fac4f7edffda9640b5a528
parentf2ed7081f2143a5e8034e8047e7b19e59b97a2d1
Add tests for simultaneous use of secondary command buffer

Fixes #335

Add simultaneousUseSecondaryBufferOnePrimaryBufferTest() test. This test
creates a single secondary command with SIMULTANEOUS_USE flag set and add
two instances of it to the same primary command buffer. Then verify that
each instance executes correctly.
Also add simultaneousUseSecondaryBufferTwoPrimaryBuffersTest(). Similar to
above test but same secondary command buffer is bound into two different
primary comman buffers that are then executed simultaneously.
In both cases the secondary command buffers are each atomically
incrementing a count from within a compute shader.

Update the mustpass lists.

Also made a few minor infrastructure additions:
Add a generic createDataBuffer() function to create a single buffer that
isn't built around a vec4 of color data.
Add a simpler createDescriptorSet() function that binds a results buffer
to binding 0 and an input uniform to binding 1.
Provide the compute result buffer initialization value in a parameter
which defaults to -1.0f. This allows flexibility for other tests that may
want a different default value, such as the new test mentioned above.

Change-Id: Icf6ebbac0e1975e1cf49f60e5aa8afb32f9885de
android/cts/master/com.drawelements.deqp.vk.xml
android/cts/master/vk-master.txt
external/vulkancts/modules/vulkan/api/vktApiBufferComputeInstance.cpp
external/vulkancts/modules/vulkan/api/vktApiBufferComputeInstance.hpp
external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
external/vulkancts/modules/vulkan/api/vktApiComputeInstanceResultBuffer.cpp
external/vulkancts/modules/vulkan/api/vktApiComputeInstanceResultBuffer.hpp
external/vulkancts/mustpass/1.0.1/vk-default.txt