Merge branch '316-dEQP-VK.api-system-memory-limitations' into 'vulkan-cts-1.0'

316-dEQP-VK.api-system-memory-limitations



Reducing the number of command buffers allocated due to system memory limitations on 32-bit systems.

This would allow us to pass these tests on 32-bit systems, which offer less system memory to the driver causing out-of-memory issues. The following are the affected tests:

* dEQP-VK.api.object_management.max_concurrent.command_buffer_primary
* dEQP-VK.api.object_management.max_concurrent.command_buffer_secondary
* dEQP-VK.api.command_buffers.allocate_many_primary
* dEQP-VK.api.command_buffers.allocate_many_secondary

Ultimately, we need to modify the test to factor in the system memory available or let a test pass if the driver reports out-of-memory errors gracefully.


See merge request !457
diff --git a/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
index cd08bd1..813e8f7 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiCommandBuffersTests.cpp
@@ -225,8 +225,12 @@
 	};
 	const Unique<VkCommandPool>				cmdPool					(createCommandPool(vk, vkDevice, &cmdPoolParams));
 
-	// create a minimal amount of command buffers - is there any minimal amount in spec?
+	// \todo Determining the minimum number of command buffers should be a function of available system memory and driver capabilities.
+#if (DE_PTR_SIZE == 4)
+	const unsigned minCommandBuffer = 1024;
+#else
 	const unsigned minCommandBuffer = 10000;
+#endif
 
 	// Command buffer
 	const VkCommandBufferAllocateInfo		cmdBufParams			=
@@ -326,8 +330,12 @@
 	};
 	const Unique<VkCommandPool>				cmdPool					(createCommandPool(vk, vkDevice, &cmdPoolParams));
 
-	// create a minimal amount of command buffers - is there any minimal amount in spec?
+	// \todo Determining the minimum number of command buffers should be a function of available system memory and driver capabilities.
+#if (DE_PTR_SIZE == 4)
+	const unsigned minCommandBuffer = 1024;
+#else
 	const unsigned minCommandBuffer = 10000;
+#endif
 
 	// Command buffer
 	const VkCommandBufferAllocateInfo		cmdBufParams			=
diff --git a/external/vulkancts/modules/vulkan/api/vktApiObjectManagementTests.cpp b/external/vulkancts/modules/vulkan/api/vktApiObjectManagementTests.cpp
index ba3dc12..3e709bc 100644
--- a/external/vulkancts/modules/vulkan/api/vktApiObjectManagementTests.cpp
+++ b/external/vulkancts/modules/vulkan/api/vktApiObjectManagementTests.cpp
@@ -1861,7 +1861,12 @@
 
 	static deUint32 getMaxConcurrent (Context&)
 	{
+		// \todo Scale this based on available system memory
+#if (DE_PTR_SIZE == 4)
+		return 1024;
+#else
 		return DEFAULT_MAX_CONCURRENT_OBJECTS;
+#endif
 	}
 
 	struct Parameters