diff --git a/src/vulkan/anv_device.c b/src/vulkan/anv_device.c index ee7682a5d9a..a12076f790d 100644 --- a/src/vulkan/anv_device.c +++ b/src/vulkan/anv_device.c @@ -535,8 +535,6 @@ anv_device_init_border_colors(struct anv_device *device) memcpy(device->border_colors.map, border_colors, sizeof(border_colors)); } -static const uint32_t BATCH_SIZE = 8192; - VkResult anv_CreateDevice( VkPhysicalDevice physicalDevice, const VkDeviceCreateInfo* pCreateInfo, @@ -568,7 +566,7 @@ VkResult anv_CreateDevice( if (device->context_id == -1) goto fail_fd; - anv_bo_pool_init(&device->batch_bo_pool, device, BATCH_SIZE); + anv_bo_pool_init(&device->batch_bo_pool, device, ANV_CMD_BUFFER_BATCH_SIZE); anv_block_pool_init(&device->dynamic_state_block_pool, device, 2048); diff --git a/src/vulkan/anv_private.h b/src/vulkan/anv_private.h index f3f50002568..0437677de0a 100644 --- a/src/vulkan/anv_private.h +++ b/src/vulkan/anv_private.h @@ -690,6 +690,8 @@ struct anv_cmd_state { struct anv_descriptor_set_binding descriptors[MAX_SETS]; }; +#define ANV_CMD_BUFFER_BATCH_SIZE 8192 + struct anv_cmd_buffer { struct anv_device * device;