From: Samuel Iglesias Gonsálvez Date: Thu, 9 Jul 2020 14:10:19 +0000 (+0200) Subject: turnip: disable LRZ on vkCmdClearAttachments() X-Git-Tag: upstream/21.0.0~4725 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2f79e0066405f80c3244d1cc814bc6a51d1d581a;p=platform%2Fupstream%2Fmesa.git turnip: disable LRZ on vkCmdClearAttachments() We don't support partial clears on LRZ. Blob disables them too. Signed-off-by: Samuel Iglesias Gonsálvez Part-of: --- diff --git a/src/freedreno/vulkan/tu_clear_blit.c b/src/freedreno/vulkan/tu_clear_blit.c index cb70ebd..f8ed2c1 100644 --- a/src/freedreno/vulkan/tu_clear_blit.c +++ b/src/freedreno/vulkan/tu_clear_blit.c @@ -2155,6 +2155,13 @@ tu_CmdClearAttachments(VkCommandBuffer commandBuffer, tu_cond_exec_start(cs, CP_COND_EXEC_0_RENDER_MODE_SYSMEM); tu_clear_sysmem_attachments(cmd, attachmentCount, pAttachments, rectCount, pRects); tu_cond_exec_end(cs); + + for (uint32_t j = 0; j < attachmentCount; j++) { + if ((pAttachments[j].aspectMask & VK_IMAGE_ASPECT_DEPTH_BIT) == 0) + continue; + cmd->state.lrz.valid = false; + cmd->state.dirty |= TU_CMD_DIRTY_LRZ; + } } static void