Add barriers to read query data after copy
authorSamuel Iglesias Gonsálvez <siglesias@igalia.com>
Fri, 17 May 2019 06:18:41 +0000 (08:18 +0200)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 24 May 2019 09:34:54 +0000 (05:34 -0400)
commite1e41026dd1fbd603ce358ace881c471d7c60549
tree5d1f6c4599f4f9d32c3e210608d95abbbef3d16a
parentfe4b129cd38ff0dba8b2049f691cb016fb77b025
Add barriers to read query data after copy

When the query pool results that were copied out to a buffer, a barrier
should be placed to ensure the data is written before the host read it,
specially if the memory allocated is non-host-coherent. The invalidation
of the mapped memory is not enough in that case.

Affected tests:

  dEQP-VK.query_pool.occlusion_query.copy*
  dEQP-VK.pipeline.timestamp.transfer_tests.*copy_query_pool_results*
  dEQP-VK.pipeline.timestamp.misc_tests.two_cmd_buffers_primary*

Components: Vulkan
VK-GL-CTS issue: 1756

Change-Id: I115c9e62f1b369e0f1ad9a30f9a6982c876beb74
external/vulkancts/modules/vulkan/pipeline/vktPipelineTimestampTests.cpp
external/vulkancts/modules/vulkan/query_pool/vktQueryPoolOcclusionTests.cpp