Merge vk-gl-cts/vulkan-cts-1.2.6 into vk-gl-cts/vulkan-cts-1.2.7
Change-Id: Iea1e614855e2a12ab124da1dd1f24f2aaa938406
diff --git a/android/cts/master/src/vk-master-2019-03-01.txt b/android/cts/master/src/vk-master-2019-03-01.txt
index dbe7a50..baef37b 100644
--- a/android/cts/master/src/vk-master-2019-03-01.txt
+++ b/android/cts/master/src/vk-master-2019-03-01.txt
@@ -3713,7 +3713,6 @@
dEQP-VK.api.device_init.create_device_features2
dEQP-VK.api.device_init.create_device_unsupported_features
dEQP-VK.api.device_init.create_device_queue2
-dEQP-VK.api.device_init.create_device_queue2_unmatched_flags
dEQP-VK.api.device_init.create_instance_device_intentional_alloc_fail
dEQP-VK.api.object_management.single.instance
dEQP-VK.api.object_management.single.device
diff --git a/android/cts/master/vk-master-2019-03-01/api.txt b/android/cts/master/vk-master-2019-03-01/api.txt
index e321ff5..2bbb089 100644
--- a/android/cts/master/vk-master-2019-03-01/api.txt
+++ b/android/cts/master/vk-master-2019-03-01/api.txt
@@ -3697,7 +3697,6 @@
dEQP-VK.api.device_init.create_device_features2
dEQP-VK.api.device_init.create_device_unsupported_features
dEQP-VK.api.device_init.create_device_queue2
-dEQP-VK.api.device_init.create_device_queue2_unmatched_flags
dEQP-VK.api.device_init.create_instance_device_intentional_alloc_fail
dEQP-VK.api.object_management.single.instance
dEQP-VK.api.object_management.single.device
diff --git a/android/cts/master/vk-master/api.txt b/android/cts/master/vk-master/api.txt
index 4f97a8c..220df02 100644
--- a/android/cts/master/vk-master/api.txt
+++ b/android/cts/master/vk-master/api.txt
@@ -3747,7 +3747,6 @@
dEQP-VK.api.device_init.create_device_features2
dEQP-VK.api.device_init.create_device_unsupported_features
dEQP-VK.api.device_init.create_device_queue2
-dEQP-VK.api.device_init.create_device_queue2_unmatched_flags
dEQP-VK.api.device_init.create_instance_device_intentional_alloc_fail
dEQP-VK.api.object_management.single.instance
dEQP-VK.api.object_management.single.device
diff --git a/external/vulkancts/modules/vulkan/api/vktApiBufferMarkerTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiBufferMarkerTests.cpp
index f502902..0a0b080 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiBufferMarkerTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiBufferMarkerTests.cpp
@@ -324,7 +324,7 @@
VK_ACCESS_HOST_READ_BIT,
};
- vk.cmdPipelineBarrier(*cmdBuffer, params.stage, VK_PIPELINE_STAGE_HOST_BIT, 0, 1, &memoryDep, 0, DE_NULL, 0, DE_NULL);
+ vk.cmdPipelineBarrier(*cmdBuffer, VK_PIPELINE_STAGE_TRANSFER_BIT, VK_PIPELINE_STAGE_HOST_BIT, 0, 1, &memoryDep, 0, DE_NULL, 0, DE_NULL);
VK_CHECK(vk.endCommandBuffer(*cmdBuffer));
@@ -488,7 +488,7 @@
DescriptorPoolBuilder descriptorPoolBuilder;
descriptorPoolBuilder.addType(VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, 1u);
- descriptorPool = descriptorPoolBuilder.build(vk, device, 0, 1u);
+ descriptorPool = descriptorPoolBuilder.build(vk, device, VK_DESCRIPTOR_POOL_CREATE_FREE_DESCRIPTOR_SET_BIT, 1u);
DescriptorSetLayoutBuilder setLayoutBuilder;
@@ -891,7 +891,7 @@
{
vk.cmdWriteBufferMarkerAMD(*cmdBuffer, params.base.stage, *markerBuffer, sizeof(deUint32) * slot, value);
- writeStages |= params.base.stage;
+ writeStages |= VK_PIPELINE_STAGE_TRANSFER_BIT;
writeAccess |= VK_ACCESS_TRANSFER_WRITE_BIT;
}
else
diff --git a/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
index afe6342..ef0feb0 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
@@ -3413,11 +3413,8 @@
// record secondary command buffer
VK_CHECK(vk.beginCommandBuffer(cmdBuffers[ndx], &secCmdBufBeginInfo));
{
- // allow execution of event during every stage of pipeline
- VkPipelineStageFlags stageMask = VK_PIPELINE_STAGE_ALL_COMMANDS_BIT;
-
// wait for event
- vk.cmdWaitEvents(cmdBuffers[ndx], 1, &eventOne.get(), stageMask, stageMask, 0, DE_NULL, 0u, DE_NULL, 0u, DE_NULL);
+ vk.cmdWaitEvents(cmdBuffers[ndx], 1, &eventOne.get(), VK_PIPELINE_STAGE_HOST_BIT, VK_PIPELINE_STAGE_ALL_COMMANDS_BIT, 0, DE_NULL, 0u, DE_NULL, 0u, DE_NULL);
}
// end recording of secondary buffers
endCommandBuffer(vk, cmdBuffers[ndx]);
diff --git a/external/vulkancts/modules/vulkan/api/vktApiCopiesAndBlittingTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiCopiesAndBlittingTests.cpp
index 6d636dc..649dd23 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiCopiesAndBlittingTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiCopiesAndBlittingTests.cpp
@@ -1132,7 +1132,7 @@
}
}
- const VkImageMemoryBarrier imageBarriers[] =
+ VkImageMemoryBarrier imageBarriers[] =
{
// source image
{
@@ -1187,6 +1187,8 @@
clearColor.float32[2] = 1.0f;
clearColor.float32[3] = 1.0f;
vk.cmdClearColorImage(*m_cmdBuffer, m_destination.get(), VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, &clearColor, 1u, &range);
+ imageBarriers[0].oldLayout = imageBarriers[0].newLayout;
+ imageBarriers[1].oldLayout = imageBarriers[1].newLayout;
vk.cmdPipelineBarrier(*m_cmdBuffer, VK_PIPELINE_STAGE_TRANSFER_BIT, VK_PIPELINE_STAGE_TRANSFER_BIT, (VkDependencyFlags)0, 0, (const VkMemoryBarrier*)DE_NULL, 0, (const VkBufferMemoryBarrier*)DE_NULL, DE_LENGTH_OF_ARRAY(imageBarriers), imageBarriers);
}
diff --git a/external/vulkancts/modules/vulkan/api/vktApiDeviceInitializationTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiDeviceInitializationTests.cpp
index 6e1c383..214abf5 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiDeviceInitializationTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiDeviceInitializationTests.cpp
@@ -1402,102 +1402,6 @@
return tcu::TestStatus::pass("Pass");
}
-tcu::TestStatus createDeviceQueue2UnmatchedFlagsTest (Context& context)
-{
- if (!context.contextSupports(vk::ApiVersion(1, 1, 0)))
- TCU_THROW(NotSupportedError, "Vulkan 1.1 is not supported");
-
- const PlatformInterface& platformInterface = context.getPlatformInterface();
- const VkInstance instance = context.getInstance();
- const InstanceInterface& instanceDriver = context.getInstanceInterface();
- const VkPhysicalDevice physicalDevice = context.getPhysicalDevice();
-
- // Check if VK_DEVICE_QUEUE_CREATE_PROTECTED_BIT flag can be used.
- {
- VkPhysicalDeviceProtectedMemoryFeatures protectedFeatures;
- protectedFeatures.sType = VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROTECTED_MEMORY_FEATURES;
- protectedFeatures.pNext = DE_NULL;
-
- VkPhysicalDeviceFeatures2 deviceFeatures;
- deviceFeatures.sType = VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FEATURES_2;
- deviceFeatures.pNext = &protectedFeatures;
-
- instanceDriver.getPhysicalDeviceFeatures2(physicalDevice, &deviceFeatures);
- if (!protectedFeatures.protectedMemory)
- {
- TCU_THROW(NotSupportedError, "protectedMemory feature is not supported, no queue creation flags available");
- }
- }
-
- const deUint32 queueFamilyIndex = context.getUniversalQueueFamilyIndex();
- const deUint32 queueCount = 1;
- const deUint32 queueIndex = 0;
- const float queuePriority = 1.0f;
- const VkDeviceQueueCreateInfo deviceQueueCreateInfo =
- {
- VK_STRUCTURE_TYPE_DEVICE_QUEUE_CREATE_INFO, // VkStructureType sType;
- DE_NULL, // const void* pNext;
- (VkDeviceQueueCreateFlags)0u, // VkDeviceQueueCreateFlags flags;
- queueFamilyIndex, // deUint32 queueFamilyIndex;
- queueCount, // deUint32 queueCount;
- &queuePriority, // const float* pQueuePriorities;
- };
- VkPhysicalDeviceProtectedMemoryFeatures protectedFeatures =
- {
- VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROTECTED_MEMORY_FEATURES, // VkStructureType sType;
- DE_NULL, // void* pNext;
- VK_TRUE // VkBool32 protectedMemory;
- };
-
- VkPhysicalDeviceFeatures emptyDeviceFeatures;
- deMemset(&emptyDeviceFeatures, 0, sizeof(emptyDeviceFeatures));
-
- const VkPhysicalDeviceFeatures2 deviceFeatures =
- {
- VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FEATURES_2, // VkStructureType sType;
- &protectedFeatures, // void* pNext;
- emptyDeviceFeatures // VkPhysicalDeviceFeatures features;
- };
-
- const VkDeviceCreateInfo deviceCreateInfo =
- {
- VK_STRUCTURE_TYPE_DEVICE_CREATE_INFO, // VkStructureType sType;
- &deviceFeatures, // const void* pNext;
- (VkDeviceCreateFlags)0u, // VkDeviceCreateFlags flags;
- 1, // deUint32 queueCreateInfoCount;
- &deviceQueueCreateInfo, // const VkDeviceQueueCreateInfo* pQueueCreateInfos;
- 0, // deUint32 enabledLayerCount;
- DE_NULL, // const char* const* ppEnabledLayerNames;
- 0, // deUint32 enabledExtensionCount;
- DE_NULL, // const char* const* ppEnabledExtensionNames;
- DE_NULL, // const VkPhysicalDeviceFeatures* pEnabledFeatures;
- };
-
- const VkDeviceQueueInfo2 deviceQueueInfo2 =
- {
- VK_STRUCTURE_TYPE_DEVICE_QUEUE_INFO_2, // VkStructureType sType;
- DE_NULL, // const void* pNext;
- VK_DEVICE_QUEUE_CREATE_PROTECTED_BIT, // VkDeviceQueueCreateFlags flags;
- queueFamilyIndex, // deUint32 queueFamilyIndex;
- queueIndex, // deUint32 queueIndex;
- };
-
- {
- const Unique<VkDevice> device (createCustomDevice(context.getTestContext().getCommandLine().isValidationEnabled(), platformInterface, instance, instanceDriver, physicalDevice, &deviceCreateInfo));
- const DeviceDriver deviceDriver (platformInterface, instance, device.get());
- const VkQueue queue2 = getDeviceQueue2(deviceDriver, *device, &deviceQueueInfo2);
-
- if (queue2 != DE_NULL)
- return tcu::TestStatus::fail("Fail, getDeviceQueue2 should return VK_NULL_HANDLE when flags in VkDeviceQueueCreateInfo and VkDeviceQueueInfo2 are different.");
-
- const VkQueue queue = getDeviceQueue(deviceDriver, *device, queueFamilyIndex, queueIndex);
-
- VK_CHECK(deviceDriver.queueWaitIdle(queue));
- }
-
- return tcu::TestStatus::pass("Pass");
-}
-
// Allocation tracking utilities
struct AllocTrack
{
@@ -1878,7 +1782,6 @@
addFunctionCase(deviceInitializationTests.get(), "create_device_features2", "", createDeviceFeatures2Test);
addFunctionCase(deviceInitializationTests.get(), "create_device_unsupported_features", "", createDeviceWithUnsupportedFeaturesTest);
addFunctionCase(deviceInitializationTests.get(), "create_device_queue2", "", createDeviceQueue2Test);
- addFunctionCase(deviceInitializationTests.get(), "create_device_queue2_unmatched_flags", "", createDeviceQueue2UnmatchedFlagsTest);
addFunctionCase(deviceInitializationTests.get(), "create_instance_device_intentional_alloc_fail", "", createInstanceDeviceIntentionalAllocFail);
return deviceInitializationTests.release();
diff --git a/external/vulkancts/modules/vulkan/api/vktApiExternalMemoryTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiExternalMemoryTests.cpp
index df63a6f..070abc0 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiExternalMemoryTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiExternalMemoryTests.cpp
@@ -609,7 +609,7 @@
is already signalled, instead of a file descriptor, . In order to make sure that a valid file descriptor is returned
we use vkCmdWaitEvents to make sure that vkQueueSubmit doesn't signal the fence.
*/
- vk.cmdWaitEvents(*cmdBuffer, 1, &event.get(), vk::VK_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT, vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, 0, DE_NULL, 0, DE_NULL, 0, DE_NULL);
+ vk.cmdWaitEvents(*cmdBuffer, 1, &event.get(), vk::VK_PIPELINE_STAGE_HOST_BIT, vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, 0, DE_NULL, 0, DE_NULL, 0, DE_NULL);
vk.endCommandBuffer(*cmdBuffer);
const vk::VkSubmitInfo submit =
@@ -722,7 +722,7 @@
file descriptor, if the fence is already signalled. In order to make sure that a valid file descriptor is returned
we use vkCmdWaitEvents to make sure that vkQueueSubmit doesn't signal the fence.
*/
- vk.cmdWaitEvents(*cmdBuffer, 1, &event.get(), vk::VK_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT, vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, 0, DE_NULL, 0, DE_NULL, 0, DE_NULL);
+ vk.cmdWaitEvents(*cmdBuffer, 1, &event.get(), vk::VK_PIPELINE_STAGE_HOST_BIT, vk::VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, 0, DE_NULL, 0, DE_NULL, 0, DE_NULL);
vk.endCommandBuffer(*cmdBuffer);
const vk::VkSubmitInfo submit =
diff --git a/external/vulkancts/modules/vulkan/api/vktApiPipelineTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiPipelineTests.cpp
index 5533e49..85a080a 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiPipelineTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiPipelineTests.cpp
@@ -588,7 +588,7 @@
const Unique<VkFramebuffer> frameBuffer (createFramebuffer(vk, device, &framebufferCreateInfo));
const Unique<VkRenderPass> renderPassB (createSimpleRenderPass(vk, device, format,
- VK_ATTACHMENT_LOAD_OP_LOAD,
+ VK_ATTACHMENT_LOAD_OP_DONT_CARE,
VK_ATTACHMENT_LOAD_OP_LOAD,
VK_ATTACHMENT_STORE_OP_STORE,
VK_IMAGE_LAYOUT_GENERAL));
diff --git a/external/vulkancts/modules/vulkan/conditional_rendering/vktConditionalDrawTests.cpp b/external/vulkancts/modules/vulkan/conditional_rendering/vktConditionalDrawTests.cpp
index e84d114..81cdef5 100644
--- a/external/vulkancts/modules/vulkan/conditional_rendering/vktConditionalDrawTests.cpp
+++ b/external/vulkancts/modules/vulkan/conditional_rendering/vktConditionalDrawTests.cpp
@@ -110,6 +110,12 @@
de::SharedPtr<Draw::Buffer> m_indirectCountBuffer;
};
+void checkSupport(Context& context, DrawCommandType command)
+{
+ if (command == DRAW_COMMAND_TYPE_DRAW_INDIRECT_COUNT || command == DRAW_COMMAND_TYPE_DRAW_INDEXED_INDIRECT_COUNT)
+ context.requireDeviceFunctionality("VK_KHR_draw_indirect_count");
+}
+
ConditionalDraw::ConditionalDraw (Context &context, ConditionalTestSpec testSpec)
: Draw::DrawTestsBaseClass(context, testSpec.shaders[glu::SHADERTYPE_VERTEX], testSpec.shaders[glu::SHADERTYPE_FRAGMENT], vk::VK_PRIMITIVE_TOPOLOGY_TRIANGLE_LIST)
, m_command(testSpec.command)
@@ -117,6 +123,7 @@
, m_conditionalData(testSpec.conditionalData)
{
checkConditionalRenderingCapabilities(context, m_conditionalData);
+ checkSupport(context, m_command);
const float minX = -0.3f;
const float maxX = 0.3f;
diff --git a/external/vulkancts/modules/vulkan/device_group/vktDeviceGroupRendering.cpp b/external/vulkancts/modules/vulkan/device_group/vktDeviceGroupRendering.cpp
index 3f0940a..c52ae22 100644
--- a/external/vulkancts/modules/vulkan/device_group/vktDeviceGroupRendering.cpp
+++ b/external/vulkancts/modules/vulkan/device_group/vktDeviceGroupRendering.cpp
@@ -402,7 +402,8 @@
vk::Move<vk::VkDeviceMemory> indexBufferMemory;
vk::Move<vk::VkDeviceMemory> uniformBufferMemory;
vk::Move<vk::VkDeviceMemory> sboBufferMemory;
- vk::Move<vk::VkDeviceMemory> imageMemory;
+ vk::Move<vk::VkDeviceMemory> renderImageMemory;
+ vk::Move<vk::VkDeviceMemory> readImageMemory;
Move<VkRenderPass> renderPass;
Move<VkImage> renderImage;
@@ -791,11 +792,19 @@
memoryTypeNdx = getMemoryIndex(memReqs.memoryTypeBits, m_useHostMemory ? 0 : VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT);
allocInfo.allocationSize = memReqs.size;
allocInfo.memoryTypeIndex = memoryTypeNdx;
- imageMemory = allocateMemory(vk, *m_deviceGroup, &allocInfo);
+ renderImageMemory = allocateMemory(vk, *m_deviceGroup, &allocInfo);
+
+ dedicatedAllocInfo.image = *readImage;
+ dedicatedAllocInfo.buffer = DE_NULL;
+ memReqs = getImageMemoryRequirements(vk, *m_deviceGroup, readImage.get());
+ memoryTypeNdx = getMemoryIndex(memReqs.memoryTypeBits, m_useHostMemory ? 0 : VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT);
+ allocInfo.allocationSize = memReqs.size;
+ allocInfo.memoryTypeIndex = memoryTypeNdx;
+ readImageMemory = allocateMemory(vk, *m_deviceGroup, &allocInfo);
}
- VK_CHECK(vk.bindImageMemory(*m_deviceGroup, *renderImage, imageMemory.get(), 0));
- VK_CHECK(vk.bindImageMemory(*m_deviceGroup, *readImage, imageMemory.get(), 0));
+ VK_CHECK(vk.bindImageMemory(*m_deviceGroup, *renderImage, renderImageMemory.get(), 0));
+ VK_CHECK(vk.bindImageMemory(*m_deviceGroup, *readImage, readImageMemory.get(), 0));
// Create renderpass
{
@@ -1186,7 +1195,7 @@
VK_STRUCTURE_TYPE_BIND_IMAGE_MEMORY_INFO, // sType
&devGroupBindInfo, // pNext
*renderImage, // image
- imageMemory.get(), // memory
+ renderImageMemory.get(), // memory
0u, // memoryOffset
};
VK_CHECK(vk.bindImageMemory2(*m_deviceGroup, 1, &bindInfo));
@@ -1475,7 +1484,7 @@
VK_STRUCTURE_TYPE_BIND_IMAGE_MEMORY_INFO, // sType
&devGroupBindInfo, // pNext
peerImage.get(), // image
- imageMemory.get(), // memory
+ renderImageMemory.get(), // memory
0u, // memoryOffset
};
VK_CHECK(vk.bindImageMemory2(*m_deviceGroup, 1, &bindInfo));
diff --git a/external/vulkancts/modules/vulkan/imageless_framebuffer/vktImagelessFramebufferTests.cpp b/external/vulkancts/modules/vulkan/imageless_framebuffer/vktImagelessFramebufferTests.cpp
index 3f27064..33cfe47 100644
--- a/external/vulkancts/modules/vulkan/imageless_framebuffer/vktImagelessFramebufferTests.cpp
+++ b/external/vulkancts/modules/vulkan/imageless_framebuffer/vktImagelessFramebufferTests.cpp
@@ -276,7 +276,7 @@
(VkAttachmentDescriptionFlags)0, // VkAttachmentDescriptionFlags flags;
colorFormat, // VkFormat format;
VK_SAMPLE_COUNT_1_BIT, // VkSampleCountFlagBits samples;
- VK_ATTACHMENT_LOAD_OP_LOAD, // VkAttachmentLoadOp loadOp;
+ VK_ATTACHMENT_LOAD_OP_DONT_CARE, // VkAttachmentLoadOp loadOp;
VK_ATTACHMENT_STORE_OP_STORE, // VkAttachmentStoreOp storeOp;
VK_ATTACHMENT_LOAD_OP_DONT_CARE, // VkAttachmentLoadOp stencilLoadOp;
VK_ATTACHMENT_STORE_OP_DONT_CARE, // VkAttachmentStoreOp stencilStoreOp;
@@ -434,7 +434,7 @@
(VkAttachmentDescriptionFlags)0, // VkAttachmentDescriptionFlags flags;
colorFormat, // VkFormat format;
VK_SAMPLE_COUNT_1_BIT, // VkSampleCountFlagBits samples;
- VK_ATTACHMENT_LOAD_OP_LOAD, // VkAttachmentLoadOp loadOp;
+ VK_ATTACHMENT_LOAD_OP_DONT_CARE, // VkAttachmentLoadOp loadOp;
VK_ATTACHMENT_STORE_OP_STORE, // VkAttachmentStoreOp storeOp;
VK_ATTACHMENT_LOAD_OP_DONT_CARE, // VkAttachmentLoadOp stencilLoadOp;
VK_ATTACHMENT_STORE_OP_DONT_CARE, // VkAttachmentStoreOp stencilStoreOp;
@@ -956,7 +956,7 @@
, m_extensions (context.requireDeviceFunctionality("VK_KHR_imageless_framebuffer"))
, m_imageExtent2D (makeExtent2D(32u, 32u))
, m_parameters (parameters)
- , m_colorImageUsage (VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT)
+ , m_colorImageUsage (VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT | VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT)
{
const InstanceInterface& vki = m_context.getInstanceInterface();
const VkPhysicalDevice physDevice = m_context.getPhysicalDevice();
diff --git a/external/vulkancts/modules/vulkan/memory/vktMemoryAllocationTests.cpp b/external/vulkancts/modules/vulkan/memory/vktMemoryAllocationTests.cpp
index d1381e7..e98b173 100644
--- a/external/vulkancts/modules/vulkan/memory/vktMemoryAllocationTests.cpp
+++ b/external/vulkancts/modules/vulkan/memory/vktMemoryAllocationTests.cpp
@@ -120,12 +120,13 @@
class BaseAllocateTestInstance : public TestInstance
{
public:
- BaseAllocateTestInstance (Context& context, bool useDeviceGroups)
- : TestInstance (context)
- , m_useDeviceGroups (useDeviceGroups)
- , m_subsetAllocationAllowed (false)
- , m_numPhysDevices (1)
- , m_memoryProperties (getPhysicalDeviceMemoryProperties(context.getInstanceInterface(), context.getPhysicalDevice()))
+ BaseAllocateTestInstance (Context& context, bool useDeviceGroups)
+ : TestInstance (context)
+ , m_useDeviceGroups (useDeviceGroups)
+ , m_subsetAllocationAllowed (false)
+ , m_numPhysDevices (1)
+ , m_memoryProperties (getPhysicalDeviceMemoryProperties(context.getInstanceInterface(), context.getPhysicalDevice()))
+ , m_deviceCoherentMemSupported (false)
{
if (m_useDeviceGroups)
createDeviceGroup();
@@ -149,6 +150,7 @@
VkMemoryAllocateFlagsInfo m_allocFlagsInfo;
deUint32 m_numPhysDevices;
VkPhysicalDeviceMemoryProperties m_memoryProperties;
+ bool m_deviceCoherentMemSupported;
private:
CustomInstance m_deviceGroupInstance;
@@ -164,7 +166,8 @@
const float queuePriority = 1.0f;
deUint32 queueFamilyIndex = 0;
bool protMemSupported = false;
- bool deviceCoherentMemSupported = false;
+
+ void* pNext = DE_NULL;
VkPhysicalDeviceProtectedMemoryFeatures protectedMemoryFeature =
{
@@ -172,14 +175,15 @@
DE_NULL, // const void* pNext
VK_FALSE // VkBool32 protectedMemory;
};
+ pNext = &protectedMemoryFeature;
VkPhysicalDeviceCoherentMemoryFeaturesAMD coherentMemoryFeatures =
{
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COHERENT_MEMORY_FEATURES_AMD, // VkStructureType sType
- &protectedMemoryFeature, // const void* pNext
+ pNext, // const void* pNext
VK_FALSE // VkBool32 deviceCoherentMemory;
};
-
+ if (m_context.isDeviceFunctionalitySupported("VK_AMD_device_coherent_memory")) pNext = &coherentMemoryFeatures;
VkPhysicalDeviceFeatures features;
deMemset(&features, 0, sizeof(vk::VkPhysicalDeviceFeatures));
@@ -187,14 +191,14 @@
VkPhysicalDeviceFeatures2 features2 =
{
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FEATURES_2, // VkStructureType sType
- &coherentMemoryFeatures, // const void* pNext
+ pNext, // const void* pNext
features // VkPhysicalDeviceFeatures features
};
// Check if the physical device supports the protected memory feature
instanceDriver.getPhysicalDeviceFeatures2(m_context.getPhysicalDevice(), &features2);
- protMemSupported = protectedMemoryFeature.protectedMemory;
- deviceCoherentMemSupported = coherentMemoryFeatures.deviceCoherentMemory;
+ protMemSupported = protectedMemoryFeature.protectedMemory;
+ m_deviceCoherentMemSupported = coherentMemoryFeatures.deviceCoherentMemory;
VkDeviceQueueCreateFlags queueCreateFlags = protMemSupported ? (vk::VkDeviceQueueCreateFlags)vk::VK_DEVICE_QUEUE_CREATE_PROTECTED_BIT : 0u;
@@ -211,7 +215,7 @@
const VkDeviceCreateInfo deviceInfo =
{
VK_STRUCTURE_TYPE_DEVICE_CREATE_INFO, // VkStructureType sType;
- (protMemSupported || deviceCoherentMemSupported) ? &features2 : DE_NULL, // const void* pNext;
+ (protMemSupported || m_deviceCoherentMemSupported) ? &features2 : DE_NULL, // const void* pNext;
(VkDeviceCreateFlags)0, // VkDeviceCreateFlags flags;
1u, // uint32_t queueCreateInfoCount;
&queueInfo, // const VkDeviceQueueCreateInfo* pQueueCreateInfos;
@@ -219,7 +223,7 @@
DE_NULL, // const char* const* ppEnabledLayerNames;
0u, // uint32_t enabledExtensionCount;
DE_NULL, // const char* const* ppEnabledExtensionNames;
- (protMemSupported || deviceCoherentMemSupported) ? DE_NULL : &deviceFeatures // const VkPhysicalDeviceFeatures* pEnabledFeatures;
+ (protMemSupported || m_deviceCoherentMemSupported) ? DE_NULL : &deviceFeatures // const VkPhysicalDeviceFeatures* pEnabledFeatures;
};
m_logicalDevice = createCustomDevice(m_context.getTestContext().getCommandLine().isValidationEnabled(), m_context.getPlatformInterface(), instance, instanceDriver, m_context.getPhysicalDevice(), &deviceInfo);
@@ -348,16 +352,23 @@
DE_FATAL("Unknown allocation order");
}
- try
+ bool memoryTypeSupported = true;
+#ifndef CTS_USES_VULKANSC
+ memoryTypeSupported = !((m_memoryProperties.memoryTypes[m_memoryTypeIndex].propertyFlags & vk::VK_MEMORY_PROPERTY_DEVICE_COHERENT_BIT_AMD) > 0 && !m_deviceCoherentMemSupported);
+#endif
+
+ if (memoryTypeSupported)
{
- const VkMemoryType memoryType = m_memoryProperties.memoryTypes[m_memoryTypeIndex];
- const VkMemoryHeap memoryHeap = m_memoryProperties.memoryHeaps[memoryType.heapIndex];
-
- // Create a buffer to get the required size
+ try
{
- const VkDeviceSize bufferSize = m_config.memorySize ? *m_config.memorySize : (VkDeviceSize) (*m_config.memoryPercentage * (float) memoryHeap.size);
+ const VkMemoryType memoryType = m_memoryProperties.memoryTypes[m_memoryTypeIndex];
+ const VkMemoryHeap memoryHeap = m_memoryProperties.memoryHeaps[memoryType.heapIndex];
- VkBufferCreateInfo bufferParams =
+ // Create a buffer to get the required size
+ {
+ const VkDeviceSize bufferSize = m_config.memorySize ? *m_config.memorySize : (VkDeviceSize)(*m_config.memoryPercentage * (float)memoryHeap.size);
+
+ VkBufferCreateInfo bufferParams =
{
VK_STRUCTURE_TYPE_BUFFER_CREATE_INFO, // VkStructureType sType;
DE_NULL, // const void* pNext;
@@ -369,144 +380,145 @@
&queueFamilyIndex, // const uint32_t* pQueueFamilyIndices;
};
- buffer = createBuffer(vkd, device, &bufferParams);
- vkd.getBufferMemoryRequirements(device, *buffer, &memReqs);
- }
+ buffer = createBuffer(vkd, device, &bufferParams);
+ vkd.getBufferMemoryRequirements(device, *buffer, &memReqs);
+ }
- const VkDeviceSize allocationSize = (m_config.memorySize ? memReqs.size : (VkDeviceSize)(*m_config.memoryPercentage * (float)memoryHeap.size));
- const VkDeviceSize roundedUpAllocationSize = roundUpToNextMultiple(allocationSize, m_memoryLimits.deviceMemoryAllocationGranularity);
- vector<VkDeviceMemory> memoryObjects (m_config.memoryAllocationCount, (VkDeviceMemory)0);
+ const VkDeviceSize allocationSize = (m_config.memorySize ? memReqs.size : (VkDeviceSize)(*m_config.memoryPercentage * (float)memoryHeap.size));
+ const VkDeviceSize roundedUpAllocationSize = roundUpToNextMultiple(allocationSize, m_memoryLimits.deviceMemoryAllocationGranularity);
+ vector<VkDeviceMemory> memoryObjects(m_config.memoryAllocationCount, (VkDeviceMemory)0);
- log << TestLog::Message << "Memory type index: " << m_memoryTypeIndex << TestLog::EndMessage;
+ log << TestLog::Message << "Memory type index: " << m_memoryTypeIndex << TestLog::EndMessage;
- if (memoryType.heapIndex >= m_memoryProperties.memoryHeapCount)
- m_result.fail("Invalid heap index defined for memory type.");
+ if (memoryType.heapIndex >= m_memoryProperties.memoryHeapCount)
+ m_result.fail("Invalid heap index defined for memory type.");
- {
- log << TestLog::Message << "Memory type: " << memoryType << TestLog::EndMessage;
- log << TestLog::Message << "Memory heap: " << memoryHeap << TestLog::EndMessage;
+ {
+ log << TestLog::Message << "Memory type: " << memoryType << TestLog::EndMessage;
+ log << TestLog::Message << "Memory heap: " << memoryHeap << TestLog::EndMessage;
- if (roundedUpAllocationSize * m_config.memoryAllocationCount > memoryHeap.size)
- TCU_THROW(NotSupportedError, "Memory heap doesn't have enough memory.");
+ if (roundedUpAllocationSize * m_config.memoryAllocationCount > memoryHeap.size)
+ TCU_THROW(NotSupportedError, "Memory heap doesn't have enough memory.");
#if (DE_PTR_SIZE == 4)
- // For 32-bit binaries we cap the total host visible allocations to 1.5GB to
- // avoid exhausting CPU virtual address space and throwing a false negative result.
- if ((memoryType.propertyFlags & VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT) &&
- allocationSize * m_config.memoryAllocationCount * (m_subsetAllocationAllowed ? 1 : m_numPhysDevices) >= 1610612736)
+ // For 32-bit binaries we cap the total host visible allocations to 1.5GB to
+ // avoid exhausting CPU virtual address space and throwing a false negative result.
+ if ((memoryType.propertyFlags & VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT) &&
+ allocationSize * m_config.memoryAllocationCount * (m_subsetAllocationAllowed ? 1 : m_numPhysDevices) >= 1610612736)
- log << TestLog::Message << " Skipping: Not enough CPU virtual address space for all host visible allocations." << TestLog::EndMessage;
- else
- {
+ log << TestLog::Message << " Skipping: Not enough CPU virtual address space for all host visible allocations." << TestLog::EndMessage;
+ else
+ {
#else
- {
+ {
#endif
- try
- {
- const deUint32 totalDeviceMaskCombinations = m_subsetAllocationAllowed ? (1 << m_numPhysDevices) - 1 : 1;
- for (deUint32 deviceMask = 1; deviceMask <= totalDeviceMaskCombinations; deviceMask++)
- {
- // Allocate on all physical devices if subset allocation is not allowed, do only once.
- if (!m_subsetAllocationAllowed)
- deviceMask = (1 << m_numPhysDevices) - 1;
- m_allocFlagsInfo.deviceMask = deviceMask;
-
- if (m_config.order == TestConfig::ALLOC_FREE || m_config.order == TestConfig::ALLOC_REVERSE_FREE)
+ try
{
- for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
+ const deUint32 totalDeviceMaskCombinations = m_subsetAllocationAllowed ? (1 << m_numPhysDevices) - 1 : 1;
+ for (deUint32 deviceMask = 1; deviceMask <= totalDeviceMaskCombinations; deviceMask++)
{
- VkMemoryAllocateInfo alloc =
+ // Allocate on all physical devices if subset allocation is not allowed, do only once.
+ if (!m_subsetAllocationAllowed)
+ deviceMask = (1 << m_numPhysDevices) - 1;
+ m_allocFlagsInfo.deviceMask = deviceMask;
+
+ if (m_config.order == TestConfig::ALLOC_FREE || m_config.order == TestConfig::ALLOC_REVERSE_FREE)
{
- VK_STRUCTURE_TYPE_MEMORY_ALLOCATE_INFO, // sType
- m_useDeviceGroups ? &m_allocFlagsInfo : DE_NULL, // pNext
- allocationSize, // allocationSize
- m_memoryTypeIndex // memoryTypeIndex;
- };
-
- VkResult res = vkd.allocateMemory(device, &alloc, (const VkAllocationCallbacks*)DE_NULL, &memoryObjects[ndx]);
-
- // Some implementations might have limitations on protected heap, and these limitations
- // don't show up in Vulkan queries. Use a hard coded threshold after which out of memory
- // is allowed.
- if (res == VK_ERROR_OUT_OF_DEVICE_MEMORY && memoryType.propertyFlags & vk::VK_MEMORY_PROPERTY_PROTECTED_BIT && ndx > 80)
- break;
-
- VK_CHECK(res);
-
- TCU_CHECK(!!memoryObjects[ndx]);
- }
-
- if (m_config.order == TestConfig::ALLOC_FREE)
- {
- for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
- {
- const VkDeviceMemory mem = memoryObjects[memoryObjects.size() - 1 - ndx];
-
- if (!!mem)
+ for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
{
- vkd.freeMemory(device, mem, (const VkAllocationCallbacks *) DE_NULL);
- memoryObjects[memoryObjects.size() - 1 - ndx] = (VkDeviceMemory) 0;
+ VkMemoryAllocateInfo alloc =
+ {
+ VK_STRUCTURE_TYPE_MEMORY_ALLOCATE_INFO, // sType
+ m_useDeviceGroups ? &m_allocFlagsInfo : DE_NULL, // pNext
+ allocationSize, // allocationSize
+ m_memoryTypeIndex // memoryTypeIndex;
+ };
+
+ VkResult res = vkd.allocateMemory(device, &alloc, (const VkAllocationCallbacks*)DE_NULL, &memoryObjects[ndx]);
+
+ // Some implementations might have limitations on protected heap, and these limitations
+ // don't show up in Vulkan queries. Use a hard coded threshold after which out of memory
+ // is allowed.
+ if (res == VK_ERROR_OUT_OF_DEVICE_MEMORY && memoryType.propertyFlags & vk::VK_MEMORY_PROPERTY_PROTECTED_BIT && ndx > 80)
+ break;
+
+ VK_CHECK(res);
+
+ TCU_CHECK(!!memoryObjects[ndx]);
+ }
+
+ if (m_config.order == TestConfig::ALLOC_FREE)
+ {
+ for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
+ {
+ const VkDeviceMemory mem = memoryObjects[memoryObjects.size() - 1 - ndx];
+
+ if (!!mem)
+ {
+ vkd.freeMemory(device, mem, (const VkAllocationCallbacks*)DE_NULL);
+ memoryObjects[memoryObjects.size() - 1 - ndx] = (VkDeviceMemory)0;
+ }
+ }
+ }
+ else
+ {
+ for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
+ {
+ const VkDeviceMemory mem = memoryObjects[ndx];
+
+ if (!!mem)
+ {
+ vkd.freeMemory(device, mem, (const VkAllocationCallbacks*)DE_NULL);
+ memoryObjects[ndx] = (VkDeviceMemory)0;
+ }
+ }
}
}
- }
- else
- {
- for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
+ else
{
- const VkDeviceMemory mem = memoryObjects[ndx];
-
- if (!!mem)
+ for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
{
- vkd.freeMemory(device, mem, (const VkAllocationCallbacks *) DE_NULL);
- memoryObjects[ndx] = (VkDeviceMemory) 0;
+ const VkMemoryAllocateInfo alloc =
+ {
+ VK_STRUCTURE_TYPE_MEMORY_ALLOCATE_INFO, // sType
+ m_useDeviceGroups ? &m_allocFlagsInfo : DE_NULL, // pNext
+ allocationSize, // allocationSize
+ m_memoryTypeIndex // memoryTypeIndex;
+ };
+
+ VK_CHECK(vkd.allocateMemory(device, &alloc, (const VkAllocationCallbacks*)DE_NULL, &memoryObjects[ndx]));
+ TCU_CHECK(!!memoryObjects[ndx]);
+
+ vkd.freeMemory(device, memoryObjects[ndx], (const VkAllocationCallbacks*)DE_NULL);
+ memoryObjects[ndx] = (VkDeviceMemory)0;
}
}
}
}
- else
+ catch (...)
{
for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
{
- const VkMemoryAllocateInfo alloc =
+ const VkDeviceMemory mem = memoryObjects[ndx];
+
+ if (!!mem)
{
- VK_STRUCTURE_TYPE_MEMORY_ALLOCATE_INFO, // sType
- m_useDeviceGroups ? &m_allocFlagsInfo : DE_NULL, // pNext
- allocationSize, // allocationSize
- m_memoryTypeIndex // memoryTypeIndex;
- };
-
- VK_CHECK(vkd.allocateMemory(device, &alloc, (const VkAllocationCallbacks*)DE_NULL, &memoryObjects[ndx]));
- TCU_CHECK(!!memoryObjects[ndx]);
-
- vkd.freeMemory(device, memoryObjects[ndx], (const VkAllocationCallbacks*)DE_NULL);
- memoryObjects[ndx] = (VkDeviceMemory)0;
+ vkd.freeMemory(device, mem, (const VkAllocationCallbacks*)DE_NULL);
+ memoryObjects[ndx] = (VkDeviceMemory)0;
+ }
}
+
+ throw;
}
}
}
- catch (...)
- {
- for (size_t ndx = 0; ndx < m_config.memoryAllocationCount; ndx++)
- {
- const VkDeviceMemory mem = memoryObjects[ndx];
-
- if (!!mem)
- {
- vkd.freeMemory(device, mem, (const VkAllocationCallbacks*)DE_NULL);
- memoryObjects[ndx] = (VkDeviceMemory)0;
- }
- }
-
- throw;
- }
}
+ catch (const tcu::TestError& error)
+ {
+ m_result.fail(error.getMessage());
}
}
- catch (const tcu::TestError& error)
- {
- m_result.fail(error.getMessage());
- }
m_memoryTypeIndex++;
@@ -626,6 +638,12 @@
TCU_CHECK(type.type.heapIndex < m_memoryProperties.memoryHeapCount);
+ if ((m_memoryProperties.memoryTypes[type.index].propertyFlags & vk::VK_MEMORY_PROPERTY_DEVICE_COHERENT_BIT_AMD) > 0 && !m_deviceCoherentMemSupported)
+ {
+ continue;
+ }
+
+
m_heaps[type.type.heapIndex].types.push_back(type);
}
}
diff --git a/external/vulkancts/modules/vulkan/pipeline/vktPipelineMultisampleTests.cpp b/external/vulkancts/modules/vulkan/pipeline/vktPipelineMultisampleTests.cpp
index 6615ada..cf3f21c 100644
--- a/external/vulkancts/modules/vulkan/pipeline/vktPipelineMultisampleTests.cpp
+++ b/external/vulkancts/modules/vulkan/pipeline/vktPipelineMultisampleTests.cpp
@@ -3163,7 +3163,7 @@
for (deUint32 attachmentIdx = 0; attachmentIdx < attachmentCount; attachmentIdx++)
attachments.push_back(m_colorBlendState);
- const VkPipelineColorBlendStateCreateInfo colorBlendStateParams =
+ VkPipelineColorBlendStateCreateInfo colorBlendStateParams =
{
VK_STRUCTURE_TYPE_PIPELINE_COLOR_BLEND_STATE_CREATE_INFO, // VkStructureType sType;
DE_NULL, // const void* pNext;
@@ -3205,6 +3205,18 @@
const deUint32 numSubpasses = m_renderType == RENDER_TYPE_DEPTHSTENCIL_ONLY ? 2u : 1u;
for (deUint32 subpassIdx = 0; subpassIdx < numSubpasses; subpassIdx++)
+ {
+ if (m_renderType == RENDER_TYPE_DEPTHSTENCIL_ONLY)
+ {
+ if (subpassIdx == 0)
+ {
+ colorBlendStateParams.attachmentCount = 0;
+ }
+ else
+ {
+ colorBlendStateParams.attachmentCount = 1;
+ }
+ }
for (deUint32 i = 0u; i < numTopologies; ++i)
{
m_graphicsPipelines.push_back(VkPipelineSp(new Unique<VkPipeline>(makeGraphicsPipeline(vk, // const DeviceInterface& vk
@@ -3227,6 +3239,7 @@
&depthStencilStateParams, // const VkPipelineDepthStencilStateCreateInfo* depthStencilStateCreateInfo
&colorBlendStateParams)))); // const VkPipelineColorBlendStateCreateInfo* colorBlendStateCreateInfo
}
+ }
}
if (m_renderType == RENDER_TYPE_COPY_SAMPLES)
diff --git a/external/vulkancts/modules/vulkan/robustness/vktRobustnessExtsTests.cpp b/external/vulkancts/modules/vulkan/robustness/vktRobustnessExtsTests.cpp
index 8fe4ba5..2a857ae 100644
--- a/external/vulkancts/modules/vulkan/robustness/vktRobustnessExtsTests.cpp
+++ b/external/vulkancts/modules/vulkan/robustness/vktRobustnessExtsTests.cpp
@@ -1722,15 +1722,26 @@
(VkDeviceSize)(m_data.bufferLen ? m_data.bufferLen : 1),
(VkDeviceSize)256);
+ VkBufferUsageFlags usage = VK_BUFFER_USAGE_VERTEX_BUFFER_BIT;
if (m_data.descriptorType == VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER ||
m_data.descriptorType == VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER_DYNAMIC)
{
size = deIntRoundToPow2((int)size, (int)robustness2Properties.robustUniformBufferAccessSizeAlignment);
+ usage |= VK_BUFFER_USAGE_UNIFORM_BUFFER_BIT;
}
else if (m_data.descriptorType == VK_DESCRIPTOR_TYPE_STORAGE_BUFFER ||
m_data.descriptorType == VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC)
{
size = deIntRoundToPow2((int)size, (int)robustness2Properties.robustStorageBufferAccessSizeAlignment);
+ usage |= VK_BUFFER_USAGE_STORAGE_BUFFER_BIT;
+ }
+ else if (m_data.descriptorType == VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER)
+ {
+ usage |= VK_BUFFER_USAGE_STORAGE_TEXEL_BUFFER_BIT;
+ }
+ else if (m_data.descriptorType == VK_DESCRIPTOR_TYPE_UNIFORM_TEXEL_BUFFER)
+ {
+ usage |= VK_BUFFER_USAGE_UNIFORM_TEXEL_BUFFER_BIT;
}
else if (m_data.descriptorType == VERTEX_ATTRIBUTE_FETCH)
{
@@ -1738,13 +1749,7 @@
}
buffer = de::MovePtr<BufferWithMemory>(new BufferWithMemory(
- vk, device, allocator, makeBufferCreateInfo(size,
- VK_BUFFER_USAGE_STORAGE_BUFFER_BIT |
- VK_BUFFER_USAGE_UNIFORM_BUFFER_BIT |
- VK_BUFFER_USAGE_UNIFORM_TEXEL_BUFFER_BIT |
- VK_BUFFER_USAGE_STORAGE_TEXEL_BUFFER_BIT |
- VK_BUFFER_USAGE_VERTEX_BUFFER_BIT),
- MemoryRequirement::HostVisible));
+ vk, device, allocator, makeBufferCreateInfo(size, usage), MemoryRequirement::HostVisible));
bufferPtr = (deUint8 *)buffer->getAllocation().getHostPtr();
deMemset(bufferPtr, 0x3f, (size_t)size);
diff --git a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp
index 631fe51..c825e8b 100644
--- a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp
+++ b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationOperation.cpp
@@ -5040,7 +5040,7 @@
// with this operation we can test pre_rasterization, index_input and attribute_input flags;
// since this operation is executed for three buffers of different size we use diferent flags depending on the size
if (m_resource.getBuffer().size > MAX_UPDATE_BUFFER_SIZE)
- stageMask = VK_PIPELINE_STAGE_2_PRE_RASTERIZATION_SHADERS_BIT_KHR;
+ stageMask = VK_PIPELINE_STAGE_2_VERTEX_INPUT_BIT_KHR;
else
stageMask = usingIndexedDraw ? VK_PIPELINE_STAGE_2_INDEX_INPUT_BIT_KHR
: VK_PIPELINE_STAGE_2_VERTEX_ATTRIBUTE_INPUT_BIT_KHR;
diff --git a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationSignalOrderTests.cpp b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationSignalOrderTests.cpp
index c9707f3..30432d5 100644
--- a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationSignalOrderTests.cpp
+++ b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationSignalOrderTests.cpp
@@ -862,7 +862,7 @@
};
// Unblock the whole lot.
- hostSignal(vkA, deviceA, semaphoreHandlesA.front(), 1);
+ hostSignal(vkA, deviceA, semaphoreHandlesA.front(), 2);
VK_CHECK(vkB.waitSemaphores(*deviceB, &waitInfo, ~0ull));
}
diff --git a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationWin32KeyedMutexTests.cpp b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationWin32KeyedMutexTests.cpp
index b558196..b087804 100644
--- a/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationWin32KeyedMutexTests.cpp
+++ b/external/vulkancts/modules/vulkan/synchronization/vktSynchronizationWin32KeyedMutexTests.cpp
@@ -178,6 +178,8 @@
extensions.push_back("VK_KHR_external_memory_win32");
extensions.push_back("VK_KHR_win32_keyed_mutex");
+ const auto& features = context.getDeviceFeatures();
+
try
{
std::vector<vk::VkDeviceQueueCreateInfo> queues;
@@ -212,7 +214,7 @@
(deUint32)extensions.size(),
extensions.empty() ? DE_NULL : &extensions[0],
- 0u
+ &features
};
return createCustomDevice(validationEnabled, vkp, instance, vki, physicalDevice, &createInfo);
diff --git a/external/vulkancts/modules/vulkan/util/vktExternalMemoryUtil.cpp b/external/vulkancts/modules/vulkan/util/vktExternalMemoryUtil.cpp
index 2e60d6c..cee5102 100644
--- a/external/vulkancts/modules/vulkan/util/vktExternalMemoryUtil.cpp
+++ b/external/vulkancts/modules/vulkan/util/vktExternalMemoryUtil.cpp
@@ -23,7 +23,7 @@
#include "vkQueryUtil.hpp"
-#if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX)
+#if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX) || (DE_OS == DE_OS_OSX)
# include <unistd.h>
# include <fcntl.h>
# include <errno.h>
@@ -73,7 +73,7 @@
{
if (other.m_fd >= 0)
{
-#if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX)
+#if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX) || (DE_OS == DE_OS_OSX)
DE_ASSERT(!other.m_win32Handle.internal);
DE_ASSERT(!other.m_androidHardwareBuffer.internal);
m_fd = dup(other.m_fd);
@@ -164,7 +164,7 @@
{
if (m_fd >= 0)
{
-#if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX)
+#if (DE_OS == DE_OS_ANDROID) || (DE_OS == DE_OS_UNIX) || (DE_OS == DE_OS_OSX)
DE_ASSERT(!m_win32Handle.internal);
DE_ASSERT(!m_androidHardwareBuffer.internal);
::close(m_fd);
diff --git a/external/vulkancts/mustpass/master/vk-default/api.txt b/external/vulkancts/mustpass/master/vk-default/api.txt
index 1dc4771..ea64d6a 100644
--- a/external/vulkancts/mustpass/master/vk-default/api.txt
+++ b/external/vulkancts/mustpass/master/vk-default/api.txt
@@ -3745,7 +3745,6 @@
dEQP-VK.api.device_init.create_device_features2
dEQP-VK.api.device_init.create_device_unsupported_features
dEQP-VK.api.device_init.create_device_queue2
-dEQP-VK.api.device_init.create_device_queue2_unmatched_flags
dEQP-VK.api.device_init.create_instance_device_intentional_alloc_fail
dEQP-VK.api.object_management.single.instance
dEQP-VK.api.object_management.single.device