From: Marek Olšák Date: Tue, 13 Oct 2020 14:33:40 +0000 (-0400) Subject: radeonsi: enable NGG culling by default on gfx10.3 dGPUs X-Git-Tag: upstream/21.0.0~3596 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7648060dc03775979e3fa8904c4948c084e82b6a;p=platform%2Fupstream%2Fmesa.git radeonsi: enable NGG culling by default on gfx10.3 dGPUs for better performance Acked-by: Pierre-Eric Pelloux-Prayer Part-of: --- diff --git a/src/gallium/drivers/radeonsi/si_state_shaders.c b/src/gallium/drivers/radeonsi/si_state_shaders.c index 3faedfc..866d458 100644 --- a/src/gallium/drivers/radeonsi/si_state_shaders.c +++ b/src/gallium/drivers/radeonsi/si_state_shaders.c @@ -2794,11 +2794,15 @@ static void *si_create_shader_selector(struct pipe_context *ctx, if (sscreen->debug_flags & DBG(ALWAYS_NGG_CULLING_ALL)) sel->ngg_cull_vert_threshold = 0; /* always enabled */ - else if (sscreen->options.shader_culling) + else if (sscreen->options.shader_culling || + (sscreen->info.chip_class == GFX10_3 && + sscreen->info.has_dedicated_vram)) sel->ngg_cull_vert_threshold = 1500; /* vertex count must be more than this */ } else if (sel->info.stage == MESA_SHADER_TESS_EVAL) { if (sscreen->debug_flags & DBG(ALWAYS_NGG_CULLING_ALL) || - sscreen->debug_flags & DBG(ALWAYS_NGG_CULLING_TESS)) + sscreen->debug_flags & DBG(ALWAYS_NGG_CULLING_TESS) || + (sscreen->info.chip_class == GFX10_3 && + sscreen->info.has_dedicated_vram)) sel->ngg_cull_vert_threshold = 0; /* always enabled */ } }