diff --git a/.pick_status.json b/.pick_status.json index 812be9caf8f..4bdce42901b 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -1444,7 +1444,7 @@ "description": "radv: Fix vkCmdCopyQueryResults -> vkCmdResetPool hazard.", "nominated": true, "nomination_type": 0, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": null }, diff --git a/src/amd/vulkan/radv_query.c b/src/amd/vulkan/radv_query.c index beff321005f..9db3d4ba2be 100644 --- a/src/amd/vulkan/radv_query.c +++ b/src/amd/vulkan/radv_query.c @@ -854,6 +854,13 @@ radv_query_shader(struct radv_cmd_buffer *cmd_buffer, VkPipeline *pipeline, radv_unaligned_dispatch(cmd_buffer, count, 1, 1); + /* Ensure that the query copy dispatch is complete before a potential vkCmdResetPool because + * there is an implicit execution dependency from each such query command to all query commands + * previously submitted to the same queue. + */ + cmd_buffer->active_query_flush_bits |= + RADV_CMD_FLAG_CS_PARTIAL_FLUSH | RADV_CMD_FLAG_INV_L2 | RADV_CMD_FLAG_INV_VCACHE; + /* Restore conditional rendering. */ cmd_buffer->state.predicating = old_predicating;