mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-03-15 08:30:42 +01:00
radv: suspend/resume dynamic rendering completely
The Vulkan spec says:
"The contents of pRenderingInfo must match between suspended
render pass instances and the render pass instances that resume
them, other than the presence or absence of the0
VK_RENDERING_RESUMING_BIT, VK_RENDERING_SUSPENDING_BIT, and
VK_RENDERING_CONTENTS_SECONDARY_COMMAND_BUFFERS_BIT flags. No
action or synchronization commands, or other render pass
instances, are allowed between suspending and resuming render
pass instances. All pairs of resuming and suspending render passes
must be submitted in the same batch. "
So it should be safe to avoid re-emitting the rendering state because
nothing can blow it up.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40004>
This commit is contained in:
parent
e6523feed9
commit
06949b74eb
1 changed files with 4 additions and 2 deletions
|
|
@ -10111,6 +10111,9 @@ radv_CmdBeginRendering(VkCommandBuffer commandBuffer, const VkRenderingInfo *pRe
|
|||
const uint32_t maxx = minx + render->area.extent.width;
|
||||
const uint32_t maxy = miny + render->area.extent.height;
|
||||
|
||||
if (pRenderingInfo->flags & VK_RENDERING_RESUMING_BIT)
|
||||
return;
|
||||
|
||||
radeon_check_space(device->ws, cs->b, 10);
|
||||
|
||||
radeon_begin(cs);
|
||||
|
|
@ -10151,8 +10154,7 @@ radv_CmdBeginRendering(VkCommandBuffer commandBuffer, const VkRenderingInfo *pRe
|
|||
|
||||
radv_emit_framebuffer_state(cmd_buffer);
|
||||
|
||||
if (!(pRenderingInfo->flags & VK_RENDERING_RESUMING_BIT))
|
||||
radv_cmd_buffer_clear_rendering(cmd_buffer, pRenderingInfo);
|
||||
radv_cmd_buffer_clear_rendering(cmd_buffer, pRenderingInfo);
|
||||
}
|
||||
|
||||
VKAPI_ATTR void VKAPI_CALL
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue