Test contradictory parameters on swapchain creation
authorRicardo Garcia <rgarcia@igalia.com>
Tue, 26 Oct 2021 11:30:52 +0000 (13:30 +0200)
committerMatthew Netsch <quic_mnetsch@quicinc.com>
Fri, 29 Oct 2021 19:19:43 +0000 (19:19 +0000)
commit567f6803304e69802146e3f0b5270254ee9e08ef
tree63872d39fd515b049ecd19e46d4d104311be286d
parent94f7d90e72dc3d94fe937eab0afbfedf6861bd63
Test contradictory parameters on swapchain creation

This commit adds new tests that check the implementation properly
ignores queueFamilyIndexCount and pQueueFamilyIndices on swapchain
creation when imageSharingMode is set to VK_SHARING_MODE_EXCLUSIVE, by
providing a null pointer in pQueueFamilyIndices and a nonzero
queueFamilyIndexCount.

In addition, swapchain creation tests using VK_SHARING_MODE_EXCLUSIVE
will no longer pass 1 in queueFamilyIndexCount and a list of
surface-compatible queues in pQueueFamilyIndices, setting
queueFamilyIndexCount to 0 and passing a null pointer instead.

Finally, the commit adds de::arrayLength as a more modern and constexpr
way of obtaining the size of statically-sized arrays, similar to
DE_LENGTH_OF_ARRAY, which can be used with static_assert.

New tests:
dEQP-VK.*exclusive_nonzero_queues

Affected tests:
dEQP-VK.*.swapchain.create.*

Components: Framework, Vulkan
VK-GL-CTS issue: 3244

Change-Id: I631aba22ac18d1fe6a2fcc8bf41890b2e8a2cc91
android/cts/master/vk-master-2021-03-01/wsi.txt
android/cts/master/vk-master/wsi.txt
external/vulkancts/modules/vulkan/wsi/vktWsiSwapchainTests.cpp
external/vulkancts/mustpass/master/vk-default/wsi.txt
framework/delibs/decpp/deDefs.hpp