mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
radv: fix restoring subpass during hw/fs color resolves
This fixes an stack-use-after-scope detect by ASAN because the subpass is used after the loop by radv_mark_noncoherent_rb(). Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14317>
This commit is contained in:
parent
030daf80b5
commit
7b7debe8f9
2 changed files with 4 additions and 4 deletions
|
|
@ -728,9 +728,9 @@ radv_cmd_buffer_resolve_subpass_hw(struct radv_cmd_buffer *cmd_buffer)
|
|||
|
||||
emit_resolve(cmd_buffer, src_img, dst_img, dest_iview->vk_format, &(VkOffset2D){0, 0},
|
||||
&(VkExtent2D){fb->width, fb->height});
|
||||
}
|
||||
|
||||
radv_cmd_buffer_restore_subpass(cmd_buffer, subpass);
|
||||
radv_cmd_buffer_restore_subpass(cmd_buffer, subpass);
|
||||
}
|
||||
|
||||
radv_meta_restore(&saved_state, cmd_buffer);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1106,9 +1106,9 @@ radv_cmd_buffer_resolve_subpass_fs(struct radv_cmd_buffer *cmd_buffer)
|
|||
|
||||
emit_resolve(cmd_buffer, src_iview, dest_iview, &(VkOffset2D){0, 0}, &(VkOffset2D){0, 0},
|
||||
&(VkExtent2D){fb->width, fb->height});
|
||||
}
|
||||
|
||||
radv_cmd_buffer_restore_subpass(cmd_buffer, subpass);
|
||||
radv_cmd_buffer_restore_subpass(cmd_buffer, subpass);
|
||||
}
|
||||
|
||||
radv_meta_restore(&saved_state, cmd_buffer);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue