tu: disable gmem in primary cmdbuffer if secondary has it disabled

If secondary command buffer is emitted within a subpass it may have
barriers which forces us to disable gmem for current renderpass.

Fixes: 20547a110e "tu: delay decision of forcing sysmem due to subpass self-dependencies"

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12219>
This commit is contained in:
Danylo Piliaiev 2021-08-05 18:45:40 +03:00
parent 6ccf11ac2b
commit 97b0981ed9

View file

@ -2755,6 +2755,8 @@ tu_CmdExecuteCommands(VkCommandBuffer commandBuffer,
cmd->state.has_tess = true;
if (secondary->state.has_subpass_predication)
cmd->state.has_subpass_predication = true;
if (secondary->state.disable_gmem)
cmd->state.disable_gmem = true;
} else {
assert(tu_cs_is_empty(&secondary->draw_cs));
assert(tu_cs_is_empty(&secondary->draw_epilogue_cs));