From: Jason Ekstrand Date: Fri, 6 Oct 2017 23:10:26 +0000 (-0700) Subject: VK_KHR_incremental_present: Trigger the fence off vkQueueSubmit X-Git-Tag: upstream/1.3.5~2565^2~6^2~86 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=db916576a76a17c02c14390fc5d5b3db1488d1d2;p=platform%2Fupstream%2FVK-GL-CTS.git VK_KHR_incremental_present: Trigger the fence off vkQueueSubmit Previously, the tests were using AcquireNextImage to trigger the fence and using it to guard the vkFreeCommandBuffers call. However, the acquire fence tells you when the PE is done with an image and when you can start rendering to it. This meant that the test was waiting for the start of the previous frame's rendering not the end before deleting the previous frame's command buffer. This meant that the previous frame's rendering could still be active on the GPU when the command buffer was freed. By triggering the fence off of the vkQueueSubmit, we wait for the end of the previous frame's rendering before freeing its command buffer. VK-GL-CTS issue: 756 Component: Vulkan Affects: dEQP-VK.wsi.*.incremental_present.* Change-Id: I87b25eb2a25e4ae48c8c527d5d63c45d89a31a30 --- diff --git a/external/vulkancts/modules/vulkan/wsi/vktWsiIncrementalPresentTests.cpp b/external/vulkancts/modules/vulkan/wsi/vktWsiIncrementalPresentTests.cpp index ec53620..0edd866 100644 --- a/external/vulkancts/modules/vulkan/wsi/vktWsiIncrementalPresentTests.cpp +++ b/external/vulkancts/modules/vulkan/wsi/vktWsiIncrementalPresentTests.cpp @@ -1191,7 +1191,7 @@ void IncrementalPresentTestInstance::render (void) deUint32 imageIndex; // Acquire next image - VK_CHECK(m_vkd.acquireNextImageKHR(*m_device, *m_swapchain, foreverNs, currentAcquireSemaphore, fence, &imageIndex)); + VK_CHECK(m_vkd.acquireNextImageKHR(*m_device, *m_swapchain, foreverNs, currentAcquireSemaphore, (vk::VkFence)0, &imageIndex)); // Create command buffer { @@ -1217,7 +1217,7 @@ void IncrementalPresentTestInstance::render (void) ¤tRenderSemaphore }; - VK_CHECK(m_vkd.queueSubmit(m_queue, 1u, &submitInfo, (vk::VkFence)0)); + VK_CHECK(m_vkd.queueSubmit(m_queue, 1u, &submitInfo, fence)); } // Present frame