radv: Only apply taskmesh indirect 0 bug workaround when necessary.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20097>
This commit is contained in:
Timur Kristóf 2022-12-01 13:24:43 +01:00
parent 50330aaccb
commit 0d36f7f76d

View file

@ -8059,9 +8059,10 @@ radv_emit_indirect_taskmesh_draw_packets(struct radv_cmd_buffer *cmd_buffer,
if (num_views > 1)
ace_predication_size += num_views * 3; /* SET_SH_REG size (view index SGPR) */
if (count_va) {
if (count_va)
radv_cs_add_buffer(ws, cmd_buffer->ace_internal.cs, info->count_buffer->bo);
if (cmd_buffer->device->physical_device->rad_info.has_taskmesh_indirect0_bug && count_va) {
/* MEC firmware bug workaround.
* When the count buffer contains zero, DISPATCH_TASKMESH_INDIRECT_MULTI_ACE hangs.
* - We must ensure that DISPATCH_TASKMESH_INDIRECT_MULTI_ACE