Fix dup tests to not free in-use semaphores/fences
authorLiam Middlebrook <lmiddlebrook@nvidia.com>
Thu, 3 Jan 2019 22:07:10 +0000 (14:07 -0800)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Thu, 10 Jan 2019 16:26:53 +0000 (11:26 -0500)
commit3baf4c62d924e16cd11aaf61b16ad6c3721562bd
tree65e8372eaefdc1f1c4ac2270e38d43c84e54513a
parent2ece81acc86cc100e458289738b21d9b8feb97cc
Fix dup tests to not free in-use semaphores/fences

The dup{,2,3} tests were subject to a race condition in which a
semaphore may be deleted before a VkQueue which was dependent on it had
completed execution.

This change moves the vkQueueWaitIdle call into the same scope as the
semaphores/fences that the queue is dependent on.

VK-GL-CTS issue: 1538

Components: Vulkan

Affects: dEQP-VK.api.external.{fence,semaphore}.opaque_fd.dup*

Change-Id: I73cf541c9c184790df44b68b8a065787634847d9
(cherry picked from commit 732a8b6800972b271735cf9b865a3612fb56dfc4)
external/vulkancts/modules/vulkan/api/vktApiExternalMemoryTests.cpp