Fix uniformBufferStandardLayout enforcement to match spec
authorChris Forbes <chrisforbes@google.com>
Thu, 29 Aug 2019 16:59:43 +0000 (09:59 -0700)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 30 Aug 2019 08:47:45 +0000 (04:47 -0400)
This extension isn't part of 1.1 -- the spec language was just unclear
if you were looking at the output. The spec has been fixed in
https://gitlab.khronos.org/vulkan/vulkan/commit/aa98ba6f89b9ea707d7efc0c8f71dd82ac9ffb60

Affects: dEQP-VK.api.info.device.mandatory_features
VK-GL-CTS Issue: 1966

Change-Id: I321730f747200036a3d635245bf978eb49b56c2c

external/vulkancts/framework/vulkan/vkMandatoryFeatures.inl
external/vulkancts/scripts/src/mandatory_features.txt

index 09b6b02..c782865 100644 (file)
@@ -79,7 +79,7 @@ bool checkMandatoryFeatures(const vkt::Context& context)
        vk::VkPhysicalDeviceUniformBufferStandardLayoutFeaturesKHR physicalDeviceUniformBufferStandardLayoutFeaturesKHR;
        deMemset(&physicalDeviceUniformBufferStandardLayoutFeaturesKHR, 0, sizeof(physicalDeviceUniformBufferStandardLayoutFeaturesKHR));
 
-       if ( context.contextSupports(vk::ApiVersion(1, 1, 0)) )
+       if ( isExtensionSupported(deviceExtensions, RequiredExtension("VK_KHR_uniform_buffer_standard_layout")) )
        {
                physicalDeviceUniformBufferStandardLayoutFeaturesKHR.sType = getStructureType<VkPhysicalDeviceUniformBufferStandardLayoutFeaturesKHR>();
                *nextPtr = &physicalDeviceUniformBufferStandardLayoutFeaturesKHR;
@@ -305,7 +305,7 @@ bool checkMandatoryFeatures(const vkt::Context& context)
                }
        }
 
-       if ( context.contextSupports(vk::ApiVersion(1, 1, 0)) )
+       if ( isExtensionSupported(deviceExtensions, RequiredExtension("VK_KHR_uniform_buffer_standard_layout")) )
        {
                if ( physicalDeviceUniformBufferStandardLayoutFeaturesKHR.uniformBufferStandardLayout == VK_FALSE )
                {
index bbb9546..0665b22 100644 (file)
@@ -29,5 +29,5 @@ VkPhysicalDeviceDescriptorIndexingFeaturesEXT                 runtimeDescriptorArray                                                          RE
 VkPhysicalDeviceInlineUniformBlockFeaturesEXT                  inlineUniformBlock                                                                      REQUIREMENTS ( VK_EXT_inline_uniform_block )
 VkPhysicalDeviceInlineUniformBlockFeaturesEXT                  descriptorBindingInlineUniformBlockUpdateAfterBind      REQUIREMENTS ( VK_EXT_inline_uniform_block VK_EXT_descriptor_indexing )
 VkPhysicalDeviceScalarBlockLayoutFeaturesEXT                   scalarBlockLayout                                                                       REQUIREMENTS ( VK_EXT_scalar_block_layout )
-VkPhysicalDeviceUniformBufferStandardLayoutFeaturesKHR uniformBufferStandardLayout                                                     REQUIREMENTS ( "ApiVersion(1, 1, 0)" )
+VkPhysicalDeviceUniformBufferStandardLayoutFeaturesKHR uniformBufferStandardLayout                                                     REQUIREMENTS ( VK_KHR_uniform_buffer_standard_layout )
 VkPhysicalDevicePipelineExecutablePropertiesFeaturesKHR        pipelineExecutableInfo                                                          REQUIREMENTS ( VK_KHR_pipeline_executable_properties )