From 6d962c2a6f1963c58e0ba3ba2f0203f6bea4cbdf Mon Sep 17 00:00:00 2001 From: Pyry Haulos Date: Thu, 30 Mar 2017 12:11:43 -0700 Subject: [PATCH] Revert "Allow old behavior in image format property tests" This reverts commit a25304112b0a3dba4082a1e7904b4f8149b2b9c8. --- .../modules/vulkan/api/vktApiFeatureInfo.cpp | 26 +++++----------------- 1 file changed, 5 insertions(+), 21 deletions(-) diff --git a/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp b/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp index 17ade0c..b947cb1 100644 --- a/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp +++ b/external/vulkancts/modules/vulkan/api/vktApiFeatureInfo.cpp @@ -2110,28 +2110,12 @@ tcu::TestStatus imageFormatProperties (Context& context, const VkFormat format, results.check(imageType != VK_IMAGE_TYPE_3D || (properties.maxExtent.width >= 1 && properties.maxExtent.height >= 1 && properties.maxExtent.depth >= 1), "Invalid dimensions for 3D image"); results.check(imageType != VK_IMAGE_TYPE_3D || properties.maxArrayLayers == 1, "Invalid maxArrayLayers for 3D image"); - if (tiling == VK_IMAGE_TILING_OPTIMAL) + if (tiling == VK_IMAGE_TILING_OPTIMAL && imageType == VK_IMAGE_TYPE_2D && !(curCreateFlags & VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT) && + ((supportedFeatures & (VK_FORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT | VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT)) || + ((supportedFeatures & VK_FORMAT_FEATURE_STORAGE_IMAGE_BIT) && deviceFeatures.shaderStorageImageMultisample))) { - // Vulkan API specification has changed since initial Android Nougat release. - // For NYC CTS we need to tolerate old behavior as well and issue compatibility - // warning instead. - // - // See spec issues 272, 282, 302, 445 and CTS issues 369, 440. - const bool requiredByNewSpec = (imageType == VK_IMAGE_TYPE_2D && !(curCreateFlags & VK_IMAGE_CREATE_CUBE_COMPATIBLE_BIT) && - ((supportedFeatures & (VK_FORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT | VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT)) || - ((supportedFeatures & VK_FORMAT_FEATURE_STORAGE_IMAGE_BIT) && deviceFeatures.shaderStorageImageMultisample))); - - if (requiredByNewSpec) - { - const VkSampleCountFlags requiredSampleCounts = getRequiredOptimalTilingSampleCounts(deviceLimits, format, curUsageFlags); - - results.check((properties.sampleCounts & requiredSampleCounts) == requiredSampleCounts, "Required sample counts not supported"); - } - else if (properties.sampleCounts != VK_SAMPLE_COUNT_1_BIT) - { - results.addResult(QP_TEST_RESULT_COMPATIBILITY_WARNING, - "Implementation supports more sample counts than allowed by the spec"); - } + const VkSampleCountFlags requiredSampleCounts = getRequiredOptimalTilingSampleCounts(deviceLimits, format, curUsageFlags); + results.check((properties.sampleCounts & requiredSampleCounts) == requiredSampleCounts, "Required sample counts not supported"); } else results.check(properties.sampleCounts == VK_SAMPLE_COUNT_1_BIT, "sampleCounts != VK_SAMPLE_COUNT_1_BIT"); -- 2.7.4