From d5567b03a1805d4fee92054c10a8271b96b95e3a Mon Sep 17 00:00:00 2001 From: ziga-lunarg Date: Sun, 11 Sep 2022 22:23:34 +0200 Subject: [PATCH] Add tests with create pipeline cache flags Add tests with pipeline cache using VK_PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT flag Components: Vulkan VK-GL-CTS issue: 3729 New tests: dEQP-VK.pipeline.*.cache.graphics_tests.vertex_stage_*_externally_synchronized Change-Id: Iac1a01a0d478a51e75fdf77c9b526cd5400af7eb --- android/cts/main/vk-master-2022-03-01/pipeline.txt | 9 ++++++++ .../vk-master/pipeline/fast-linked-library.txt | 3 +++ android/cts/main/vk-master/pipeline/monolithic.txt | 3 +++ .../main/vk-master/pipeline/pipeline-library.txt | 3 +++ .../vulkan/pipeline/vktPipelineCacheTests.cpp | 27 +++++++++++++++++----- .../vk-default/pipeline/fast-linked-library.txt | 3 +++ .../main/vk-default/pipeline/monolithic.txt | 3 +++ .../main/vk-default/pipeline/pipeline-library.txt | 3 +++ 8 files changed, 48 insertions(+), 6 deletions(-) diff --git a/android/cts/main/vk-master-2022-03-01/pipeline.txt b/android/cts/main/vk-master-2022-03-01/pipeline.txt index bb4e932..d537d5c 100644 --- a/android/cts/main/vk-master-2022-03-01/pipeline.txt +++ b/android/cts/main/vk-master-2022-03-01/pipeline.txt @@ -205055,6 +205055,9 @@ dEQP-VK.pipeline.pipeline_library.timestamp.advanced_graphics_tests.geometry_sha dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage @@ -284910,6 +284913,9 @@ dEQP-VK.pipeline.monolithic.timestamp.misc_tests.two_cmd_buffers_secondary_with_ dEQP-VK.pipeline.monolithic.timestamp.misc_tests.timestamp_only_host_query_reset_with_availability_bit dEQP-VK.pipeline.monolithic.timestamp.misc_tests.two_cmd_buffers_primary_host_query_reset_with_availability_bit dEQP-VK.pipeline.monolithic.timestamp.misc_tests.two_cmd_buffers_secondary_host_query_reset_with_availability_bit +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.monolithic.framebuffer_attachment.resolve_input_same_attachment dEQP-VK.pipeline.monolithic.shader_stencil_export.s8_uint.op_replace_early_and_late dEQP-VK.pipeline.monolithic.shader_stencil_export.d24_unorm_s8_uint.op_replace_early_and_late @@ -494542,6 +494548,9 @@ dEQP-VK.pipeline.fast_linked_library.timestamp.advanced_graphics_tests.geometry_ dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage diff --git a/android/cts/main/vk-master/pipeline/fast-linked-library.txt b/android/cts/main/vk-master/pipeline/fast-linked-library.txt index 1008a00..26a8702 100644 --- a/android/cts/main/vk-master/pipeline/fast-linked-library.txt +++ b/android/cts/main/vk-master/pipeline/fast-linked-library.txt @@ -205055,6 +205055,9 @@ dEQP-VK.pipeline.fast_linked_library.timestamp.advanced_graphics_tests.geometry_ dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage diff --git a/android/cts/main/vk-master/pipeline/monolithic.txt b/android/cts/main/vk-master/pipeline/monolithic.txt index 53bdcc4..aaff767 100644 --- a/android/cts/main/vk-master/pipeline/monolithic.txt +++ b/android/cts/main/vk-master/pipeline/monolithic.txt @@ -205785,6 +205785,9 @@ dEQP-VK.pipeline.monolithic.timestamp.misc_tests.consistent_results dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.monolithic.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage diff --git a/android/cts/main/vk-master/pipeline/pipeline-library.txt b/android/cts/main/vk-master/pipeline/pipeline-library.txt index 76e2352..0f003bd 100644 --- a/android/cts/main/vk-master/pipeline/pipeline-library.txt +++ b/android/cts/main/vk-master/pipeline/pipeline-library.txt @@ -205055,6 +205055,9 @@ dEQP-VK.pipeline.pipeline_library.timestamp.advanced_graphics_tests.geometry_sha dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage diff --git a/external/vulkancts/modules/vulkan/pipeline/vktPipelineCacheTests.cpp b/external/vulkancts/modules/vulkan/pipeline/vktPipelineCacheTests.cpp index fc5cd35..4d5d8c1 100644 --- a/external/vulkancts/modules/vulkan/pipeline/vktPipelineCacheTests.cpp +++ b/external/vulkancts/modules/vulkan/pipeline/vktPipelineCacheTests.cpp @@ -87,36 +87,48 @@ class CacheTestParam public: CacheTestParam (PipelineConstructionType pipelineConstructionType, const VkShaderStageFlags shaders, - bool compileCacheMissShaders); + bool compileCacheMissShaders, + VkPipelineCacheCreateFlags pipelineCacheCreateFlags = 0u); virtual ~CacheTestParam (void) = default; virtual const std::string generateTestName (void) const; virtual const std::string generateTestDescription (void) const; - PipelineConstructionType getPipelineConstructionType (void) const { return m_pipelineConstructionType; }; + PipelineConstructionType getPipelineConstructionType (void) const { return m_pipelineConstructionType; } VkShaderStageFlags getShaderFlags (void) const { return m_shaders; } + VkPipelineCacheCreateFlags getPipelineCacheCreateFlags (void) const { return m_pipelineCacheCreateFlags; } bool getCompileMissShaders (void) const { return m_compileCacheMissShaders; } protected: PipelineConstructionType m_pipelineConstructionType; VkShaderStageFlags m_shaders; + VkPipelineCacheCreateFlags m_pipelineCacheCreateFlags; bool m_compileCacheMissShaders; }; -CacheTestParam::CacheTestParam (PipelineConstructionType pipelineConstructionType, const VkShaderStageFlags shaders, bool compileCacheMissShaders) +CacheTestParam::CacheTestParam (PipelineConstructionType pipelineConstructionType, const VkShaderStageFlags shaders, bool compileCacheMissShaders, VkPipelineCacheCreateFlags pipelineCacheCreateFlags) : m_pipelineConstructionType (pipelineConstructionType) , m_shaders (shaders) + , m_pipelineCacheCreateFlags(pipelineCacheCreateFlags) , m_compileCacheMissShaders (compileCacheMissShaders) { } const std::string CacheTestParam::generateTestName (void) const { - return getShaderFlagStr(m_shaders, false); + std::string name = getShaderFlagStr(m_shaders, false); + if (m_pipelineCacheCreateFlags == VK_PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT) { + name += "_externally_synchronized"; + } + return name; } const std::string CacheTestParam::generateTestDescription (void) const { - return getShaderFlagStr(m_shaders, true); + std::string description = getShaderFlagStr(m_shaders, true); + if (m_pipelineCacheCreateFlags == VK_PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT) { + description += "with externally synchronized bit"; + } + return description; } template @@ -254,7 +266,7 @@ CacheTestInstance::CacheTestInstance (Context& context, { VK_STRUCTURE_TYPE_PIPELINE_CACHE_CREATE_INFO, // VkStructureType sType; DE_NULL, // const void* pNext; - 0u, // VkPipelineCacheCreateFlags flags; + m_param->getPipelineCacheCreateFlags(), // VkPipelineCacheCreateFlags flags; 0u, // deUintptr initialDataSize; DE_NULL, // const void* pInitialData; }; @@ -1827,6 +1839,9 @@ tcu::TestCaseGroup* createCacheTests (tcu::TestContext& testCtx, PipelineConstru CacheTestParam(pipelineConstructionType, vertFragStages, false), CacheTestParam(pipelineConstructionType, vertGeomFragStages, false), CacheTestParam(pipelineConstructionType, vertTesFragStages, false), + CacheTestParam(pipelineConstructionType, vertFragStages, false, VK_PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT), + CacheTestParam(pipelineConstructionType, vertGeomFragStages, false, VK_PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT), + CacheTestParam(pipelineConstructionType, vertTesFragStages, false, VK_PIPELINE_CACHE_CREATE_EXTERNALLY_SYNCHRONIZED_BIT), }; for (deUint32 i = 0; i < DE_LENGTH_OF_ARRAY(testParams); i++) diff --git a/external/vulkancts/mustpass/main/vk-default/pipeline/fast-linked-library.txt b/external/vulkancts/mustpass/main/vk-default/pipeline/fast-linked-library.txt index b613e1e..36bd361 100644 --- a/external/vulkancts/mustpass/main/vk-default/pipeline/fast-linked-library.txt +++ b/external/vulkancts/mustpass/main/vk-default/pipeline/fast-linked-library.txt @@ -205096,6 +205096,9 @@ dEQP-VK.pipeline.fast_linked_library.timestamp.advanced_graphics_tests.geometry_ dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.fast_linked_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.fast_linked_library.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage diff --git a/external/vulkancts/mustpass/main/vk-default/pipeline/monolithic.txt b/external/vulkancts/mustpass/main/vk-default/pipeline/monolithic.txt index 6394483..8961a46 100644 --- a/external/vulkancts/mustpass/main/vk-default/pipeline/monolithic.txt +++ b/external/vulkancts/mustpass/main/vk-default/pipeline/monolithic.txt @@ -205826,6 +205826,9 @@ dEQP-VK.pipeline.monolithic.timestamp.misc_tests.consistent_results dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.monolithic.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.monolithic.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.monolithic.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage diff --git a/external/vulkancts/mustpass/main/vk-default/pipeline/pipeline-library.txt b/external/vulkancts/mustpass/main/vk-default/pipeline/pipeline-library.txt index 5b34af4..a48e1e9 100644 --- a/external/vulkancts/mustpass/main/vk-default/pipeline/pipeline-library.txt +++ b/external/vulkancts/mustpass/main/vk-default/pipeline/pipeline-library.txt @@ -205096,6 +205096,9 @@ dEQP-VK.pipeline.pipeline_library.timestamp.advanced_graphics_tests.geometry_sha dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_geometry_stage_fragment_stage_externally_synchronized +dEQP-VK.pipeline.pipeline_library.cache.graphics_tests.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage_externally_synchronized dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_geometry_stage_fragment_stage dEQP-VK.pipeline.pipeline_library.cache.pipeline_from_get_data.vertex_stage_tessellation_control_stage_tessellation_evaluation_stage_fragment_stage -- 2.7.4