From 2e32644e35f34c70d8c038c66243b7cf633bc5bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ma=C3=ADra=20Canal?= Date: Mon, 7 Aug 2023 14:13:54 -0300 Subject: [PATCH] v3dv: occlusion queries aren't handled with a CPU job MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A CPU job of type V3DV_JOB_TYPE_CPU_RESET_QUERIES is only created for performance and timestamp queries. Occlusion queries are handled with a compute job. Therefore, there is no need to handle occlusion queries in the CPU job. Signed-off-by: MaĆ­ra Canal Reviewed-by: Iago Toral Quiroga Part-of: --- src/broadcom/vulkan/v3dv_queue.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/broadcom/vulkan/v3dv_queue.c b/src/broadcom/vulkan/v3dv_queue.c index aede121f6cb..2e19320d1dd 100644 --- a/src/broadcom/vulkan/v3dv_queue.c +++ b/src/broadcom/vulkan/v3dv_queue.c @@ -315,12 +315,11 @@ handle_reset_query_cpu_job(struct v3dv_queue *queue, struct v3dv_job *job, struct v3dv_reset_query_cpu_job_info *info = &job->cpu.query_reset; assert(info->pool); + assert(info->pool->query_type != VK_QUERY_TYPE_OCCLUSION); + /* We are about to reset query counters so we need to make sure that * The GPU is not using them. */ - if (info->pool->query_type == VK_QUERY_TYPE_OCCLUSION) - v3dv_bo_wait(job->device, info->pool->occlusion.bo, OS_TIMEOUT_INFINITE); - if (info->pool->query_type == VK_QUERY_TYPE_TIMESTAMP) { VkResult result = queue_wait_idle(queue, sync_info); if (result != VK_SUCCESS)