From f2876c0c252036f4ea13ff36ae34ef711d7b35eb Mon Sep 17 00:00:00 2001 From: Piers Daniell Date: Fri, 20 Jan 2023 14:36:35 -0700 Subject: [PATCH] Fix to EDS3 tests for platforms that don't support mixed samples The EDS3 tests for rasterizationSamples that use the two-draws sequence hit a condition where the framebuffer sample count does not match the rasterization sample count. This is only valid usage on platforms that implement VK_AMD_mixed_attachment_samples or VK_NV_framebuffer_mixed_samples. Affects: dEQP-VK.pipeline.*.extended_dynamic_state.* Components: Vulkan VK-GL-CTS issue: 4220 Change-Id: I6e846a5c217656cc305b607d78c75a70d2e21fd7 --- .../vulkan/pipeline/vktPipelineExtendedDynamicStateTests.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/external/vulkancts/modules/vulkan/pipeline/vktPipelineExtendedDynamicStateTests.cpp b/external/vulkancts/modules/vulkan/pipeline/vktPipelineExtendedDynamicStateTests.cpp index 8d24e4a..4d5b601 100644 --- a/external/vulkancts/modules/vulkan/pipeline/vktPipelineExtendedDynamicStateTests.cpp +++ b/external/vulkancts/modules/vulkan/pipeline/vktPipelineExtendedDynamicStateTests.cpp @@ -2518,6 +2518,17 @@ void ExtendedDynamicStateTest::checkSupport (Context& context) const for (const auto& extension : requiredExtensions) context.requireDeviceFunctionality(extension); + // Special requirement for rasterizationSamples tests. + // The first iteration of these tests puts the pipeline in a mixed samples state, + // where colorCount != rasterizationSamples. + if (m_testConfig.rasterizationSamplesConfig.dynamicValue && + (m_testConfig.sequenceOrdering == SequenceOrdering::TWO_DRAWS_DYNAMIC || + m_testConfig.sequenceOrdering == SequenceOrdering::TWO_DRAWS_STATIC) && + !context.isDeviceFunctionalitySupported("VK_AMD_mixed_attachment_samples") && + !context.isDeviceFunctionalitySupported("VK_NV_framebuffer_mixed_samples")) + + TCU_THROW(NotSupportedError, "VK_AMD_mixed_attachment_samples or VK_NV_framebuffer_mixed_samples are not supported"); + // Check the number of viewports needed and the corresponding limits. const auto& viewportConfig = m_testConfig.viewportConfig; auto numViewports = viewportConfig.staticValue.size(); -- 2.7.4