Avoid using custom instances in robustness tests
authorRicardo Garcia <rgarcia@igalia.com>
Mon, 28 Nov 2022 12:20:50 +0000 (13:20 +0100)
committerMatthew Netsch <quic_mnetsch@quicinc.com>
Thu, 1 Dec 2022 23:40:50 +0000 (23:40 +0000)
commit203224c9a22e62f9ad9e4f13109160f0c7ee8a7d
treea7d0382d84ed0da8aa7e139c2e9c041ff9a3ac89
parent6dfa0b69b46e69bdabd213ec2cf915bcd6e689f3
Avoid using custom instances in robustness tests

Some robustness custom devices are created with a large amount of
enabled extensions and features, using the default device as a
reference. Some drivers may expose or hide different device extensions
depending on the enabled instance extensions.

This means if we use a custom instance with no extensions and try to
enable everything that's available on the default device, device
creation may fail unexpectedly. This can be solved in two ways:

* Create the custom instance with the same extensions as the default
  instance.

* Avoid creating a custom instance at all and reuse the context
  instance.

This commit opts for the second option. Creating a custom instance is
rarely useful. The focus of robustness tests in on creating a custom
device with robustness features.

In addition, this commit also fixes some cases where the code was mixing
the context DeviceInterface with custom devices, and fixes validation
errors caused by the tests failing to enable shaderInt64 or vert/frag
stores and atomics in cases they were needed.

Affects:
dEQP-VK.robustness.*
dEQP-VKSC.robustness.*

VK-GL-CTS issue: 4136
Components: Vulkan

Change-Id: I820f8932e74100f01dba397ccf9eac24042ce33d
external/vulkancts/modules/vulkan/robustness/vktRobustBufferAccessWithVariablePointersTests.cpp
external/vulkancts/modules/vulkan/robustness/vktRobustness1VertexAccessTests.cpp
external/vulkancts/modules/vulkan/robustness/vktRobustnessBufferAccessTests.cpp
external/vulkancts/modules/vulkan/robustness/vktRobustnessExtsTests.cpp
external/vulkancts/modules/vulkan/robustness/vktRobustnessUtil.cpp
external/vulkancts/modules/vulkan/robustness/vktRobustnessUtil.hpp
external/vulkancts/modules/vulkan/robustness/vktRobustnessVertexAccessTests.cpp