Fixes image sparse tests
authorMatthew Netsch <quic_mnetsch@quicinc.com>
Thu, 6 May 2021 19:30:22 +0000 (15:30 -0400)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Thu, 13 May 2021 12:31:44 +0000 (12:31 +0000)
Tests use sparseImageLoadARB in shader
but not checking for sparse_residency

Components: Vulkan
VK-GL-CTS Issue: 2913

Affects:
dEQP-VK.image.mismatched_formats.sparse_image_read*

Change-Id: I6896c7cec530a69be8ea172205d9155ff71873f9

external/vulkancts/modules/vulkan/image/vktImageMismatchedFormatsTests.cpp

index ec29a43f2270c07fdac2a24913281a51e3b69bb8..4911b8f3395ddf3396f71eb605e9ead467cb0d17 100644 (file)
@@ -233,6 +233,11 @@ void MismatchedFormatTest::checkSupport (Context& context) const
                {
                        TCU_THROW(NotSupportedError, "Sparse partially resident buffers not supported");
                }
+
+               if (!getPhysicalDeviceFeatures(context.getInstanceInterface(), context.getPhysicalDevice()).shaderResourceResidency)
+               {
+                       TCU_THROW(NotSupportedError, "Shader resource residency not supported");
+               }
        }
 
        VkFormatProperties formatProperties = getPhysicalDeviceFormatProperties(context.getInstanceInterface(), context.getPhysicalDevice(), m_format);