aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNanley Chery <[email protected]>2017-02-27 09:38:25 -0800
committerNanley Chery <[email protected]>2017-03-02 13:17:55 -0800
commit8f6a17c8e73c8edd181ce0afe0f8cbb1e726f65f (patch)
tree660362ab7805f38e069415093314e8635dbdf5fc
parent608d17b80e617b0052b148083d169d97e8f81ab3 (diff)
anv/pass: Fix size of anv_render_pass:subpass_attachments
Don't allocate space for resolve attachments if the subpass has none. Signed-off-by: Nanley Chery <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
-rw-r--r--src/intel/vulkan/anv_pass.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/intel/vulkan/anv_pass.c b/src/intel/vulkan/anv_pass.c
index 399ccb3970f..5bd205d2f03 100644
--- a/src/intel/vulkan/anv_pass.c
+++ b/src/intel/vulkan/anv_pass.c
@@ -88,8 +88,7 @@ VkResult anv_CreateRenderPass(
subpass_attachment_count +=
desc->inputAttachmentCount +
desc->colorAttachmentCount +
- /* Count colorAttachmentCount again for resolve_attachments */
- desc->colorAttachmentCount;
+ (desc->pResolveAttachments ? desc->colorAttachmentCount : 0);
}
pass->subpass_attachments =