From 3c9aa3e20136b65d794c36ebc5cb1311d1478f4b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Sat, 25 Feb 2023 18:50:23 -0500 Subject: [PATCH] amd/rtld: allow 64K LDS for all shader stages except for gfx6 Gfx6 can only use 32K LDS per workgroup. Reviewed-by: Samuel Pitoiset Reviewed-by: Pierre-Eric Pelloux-Prayer Part-of: --- src/amd/common/ac_rtld.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/amd/common/ac_rtld.c b/src/amd/common/ac_rtld.c index 03f8adf..34553d7 100644 --- a/src/amd/common/ac_rtld.c +++ b/src/amd/common/ac_rtld.c @@ -295,11 +295,7 @@ bool ac_rtld_open(struct ac_rtld_binary *binary, struct ac_rtld_open_info i) util_dynarray_foreach (&binary->lds_symbols, struct ac_rtld_symbol, symbol) symbol->part_idx = ~0u; - unsigned max_lds_size = 64 * 1024; - - if (i.info->gfx_level == GFX6 || - (i.shader_type != MESA_SHADER_COMPUTE && i.shader_type != MESA_SHADER_FRAGMENT)) - max_lds_size = 32 * 1024; + unsigned max_lds_size = i.info->gfx_level == GFX6 ? 32 * 1024 : 64 * 1024; uint64_t shared_lds_size = 0; if (!layout_symbols(binary->lds_symbols.data, i.num_shared_lds_symbols, &shared_lds_size)) -- 2.7.4