From 02b601594587e8d7462a353039108241aa4ab81a Mon Sep 17 00:00:00 2001 From: Bas Nieuwenhuizen Date: Sun, 8 Aug 2021 14:37:52 +0200 Subject: [PATCH] radv: Allocate space for inline push constants. In the compute dispatch path we do not allocate a huge amount of space to cover everything so the individual functions have to allocate. This was missing here, causing a hang in Cyberpunk when accessing the system menu at some locations with thread tracing enabled. Fixes: bd1186572f6 ("radv: add support for push constants inlining when possible") Reviewed-by: Samuel Pitoiset Part-of: --- src/amd/vulkan/radv_cmd_buffer.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c index feb78d628c3..4ba59c80aae 100644 --- a/src/amd/vulkan/radv_cmd_buffer.c +++ b/src/amd/vulkan/radv_cmd_buffer.c @@ -982,6 +982,8 @@ radv_emit_inline_push_consts(struct radv_cmd_buffer *cmd_buffer, struct radv_pip assert(loc->num_sgprs == count); + radeon_check_space(cmd_buffer->device->ws, cmd_buffer->cs, 2 + count); + radeon_set_sh_reg_seq(cmd_buffer->cs, base_reg + loc->sgpr_idx * 4, count); radeon_emit_array(cmd_buffer->cs, values, count); }