Mesa (main): radv: do not perform depth/stencil resolves for suspended render pass

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Dec 10 22:25:55 UTC 2021


Module: Mesa
Branch: main
Commit: e2ad92eb22d4419a9ce702de143fed36ab7aa2ba
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=e2ad92eb22d4419a9ce702de143fed36ab7aa2ba

Author: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Date:   Tue Dec  7 17:33:55 2021 +0100

radv: do not perform depth/stencil resolves for suspended render pass

>From the Vulkan spec:

    "Store and resolve operations are only performed at the end of a
     render pass instance that does not specify the
     VK_RENDERING_SUSPENDING_BIT_KHR flag."

Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14112>

---

 src/amd/vulkan/radv_cmd_buffer.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c
index 803834cd514..6cfb8497482 100644
--- a/src/amd/vulkan/radv_cmd_buffer.c
+++ b/src/amd/vulkan/radv_cmd_buffer.c
@@ -7579,10 +7579,11 @@ radv_CmdBeginRenderingKHR(VkCommandBuffer commandBuffer, const VkRenderingInfoKH
             };
          }
 
-         if ((pRenderingInfo->pDepthAttachment &&
+         if (((pRenderingInfo->pDepthAttachment &&
               pRenderingInfo->pDepthAttachment->resolveMode != VK_RESOLVE_MODE_NONE) ||
              (pRenderingInfo->pStencilAttachment &&
-              pRenderingInfo->pStencilAttachment->resolveMode != VK_RESOLVE_MODE_NONE)) {
+              pRenderingInfo->pStencilAttachment->resolveMode != VK_RESOLVE_MODE_NONE)) &&
+             !(pRenderingInfo->flags & VK_RENDERING_SUSPENDING_BIT_KHR)) {
             RADV_FROM_HANDLE(radv_image_view, resolve_iview, common_info->resolveImageView);
             ds_resolve_ref =
                (VkAttachmentReference2){.sType = VK_STRUCTURE_TYPE_ATTACHMENT_REFERENCE_2,



More information about the mesa-commit mailing list