From: Mika Isojärvi Date: Fri, 27 May 2016 21:05:20 +0000 (-0700) Subject: Flush changes before invalidate in memory mapping tests X-Git-Tag: upstream/0.1.0~671^2~19 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e73ac75e3c0ee3068e2366bf69a83c77f3dba268;p=platform%2Fupstream%2FVK-GL-CTS.git Flush changes before invalidate in memory mapping tests Bug: 29006045 Change-Id: I697c69838bc75d0dfc7ac232888d60e1a0d80ded --- diff --git a/external/vulkancts/modules/vulkan/memory/vktMemoryMappingTests.cpp b/external/vulkancts/modules/vulkan/memory/vktMemoryMappingTests.cpp index f9470c2..ce3986b 100644 --- a/external/vulkancts/modules/vulkan/memory/vktMemoryMappingTests.cpp +++ b/external/vulkancts/modules/vulkan/memory/vktMemoryMappingTests.cpp @@ -1028,18 +1028,23 @@ TestConfig subMappedConfig (VkDeviceSize allocationSize, return config; case OP_INVALIDATE: + config.flushMappings = vector(1, MemoryRange(mapping.offset, mapping.size)); config.invalidateMappings = vector(1, MemoryRange(mapping.offset, mapping.size)); return config; case OP_SUB_INVALIDATE: DE_ASSERT(mapping.size / 4 > 0); + config.flushMappings = vector(1, MemoryRange(mapping.offset + mapping.size / 4, mapping.size / 2)); config.invalidateMappings = vector(1, MemoryRange(mapping.offset + mapping.size / 4, mapping.size / 2)); return config; case OP_SUB_INVALIDATE_SEPARATE: DE_ASSERT(mapping.size / 2 > 0); + config.flushMappings.push_back(MemoryRange(mapping.offset + mapping.size / 2, mapping.size - (mapping.size / 2))); + config.flushMappings.push_back(MemoryRange(mapping.offset, mapping.size / 2)); + config.invalidateMappings.push_back(MemoryRange(mapping.offset + mapping.size / 2, mapping.size - (mapping.size / 2))); config.invalidateMappings.push_back(MemoryRange(mapping.offset, mapping.size / 2)); @@ -1048,6 +1053,9 @@ TestConfig subMappedConfig (VkDeviceSize allocationSize, case OP_SUB_INVALIDATE_OVERLAPPING: DE_ASSERT((mapping.size / 3) > 0); + config.flushMappings.push_back(MemoryRange(mapping.offset + mapping.size / 3, mapping.size - (mapping.size / 2))); + config.flushMappings.push_back(MemoryRange(mapping.offset, (2 * mapping.size) / 3)); + config.invalidateMappings.push_back(MemoryRange(mapping.offset + mapping.size / 3, mapping.size - (mapping.size / 2))); config.invalidateMappings.push_back(MemoryRange(mapping.offset, (2 * mapping.size) / 3));