Merge vk-gl-cts/vulkan-cts-1.3.2 to vk-gl-cts/vulkan-cts-1.3.3
authorMatthew Netsch <quic_mnetsch@quicinc.com>
Thu, 21 Jul 2022 18:30:59 +0000 (11:30 -0700)
committerMatthew Netsch <quic_mnetsch@quicinc.com>
Thu, 21 Jul 2022 18:30:59 +0000 (11:30 -0700)
Change-Id: I5c0bfb8a853ed3d97f2e10d90c1dcef6ab8580e2

1  2 
external/vulkancts/modules/vulkan/api/vktApiBufferTests.cpp
external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
external/vulkancts/modules/vulkan/descriptor_indexing/vktDescriptorSetsIndexingTests.cpp
external/vulkancts/modules/vulkan/texture/vktTextureConversionTests.cpp

@@@ -696,19 -679,21 +696,24 @@@ struct LargeBufferParameter
        VkBufferCreateFlags             flags;
  };
  
 +#ifndef CTS_USES_VULKANSC
  tcu::TestStatus testLargeBuffer(Context& context, LargeBufferParameters params)
  {
-       const DeviceInterface&  vk                                      = context.getDeviceInterface();
-       const VkDevice                  vkDevice                        = context.getDevice();
-       const deUint32                  queueFamilyIndex        = context.getUniversalQueueFamilyIndex();
-       VkBuffer                                rawBuffer                       = DE_NULL;
+       const DeviceInterface&                  vk                                      = context.getDeviceInterface();
+       const VkDevice                                  vkDevice                        = context.getDevice();
+       const deUint32                                  queueFamilyIndex        = context.getUniversalQueueFamilyIndex();
+       const VkPhysicalDeviceLimits    limits                          = getPhysicalDeviceProperties(context.getInstanceInterface(),
+                                                                                                     context.getPhysicalDevice()).limits;
+       VkBuffer                                                rawBuffer                       = DE_NULL;
  
 +#ifndef CTS_USES_VULKANSC
        if (params.useMaxBufferSize)
                params.bufferSize = context.getMaintenance4Properties().maxBufferSize;
 +#endif // CTS_USES_VULKANSC
  
+       if ((params.flags & VK_BUFFER_CREATE_SPARSE_BINDING_BIT) != 0)
+               params.bufferSize = std::min(params.bufferSize, limits.sparseAddressSpaceSize);
        VkBufferCreateInfo bufferParams =
        {
                VK_STRUCTURE_TYPE_BUFFER_CREATE_INFO,   // VkStructureType                      sType;