From 8d7846cfed6d83a18a01670af1c1af0877014b04 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Wed, 18 Aug 2021 11:14:26 -0400 Subject: [PATCH] radeonsi: reduce the frequency of switching GS fast launch on/off Acked-by: Pierre-Eric Pelloux-Prayer Part-of: --- src/gallium/drivers/radeonsi/si_state_draw.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gallium/drivers/radeonsi/si_state_draw.cpp b/src/gallium/drivers/radeonsi/si_state_draw.cpp index f4a6ef7..f8084e8 100644 --- a/src/gallium/drivers/radeonsi/si_state_draw.cpp +++ b/src/gallium/drivers/radeonsi/si_state_draw.cpp @@ -1854,11 +1854,11 @@ static void si_draw_vbo(struct pipe_context *ctx, * A draw must have at least 1 full primitive. * The fast launch doesn't work with tessellation. * - * Small instances (including small draws) don't perform well with fast launch. - * It's better to use normal launch with NOT_EOP for small draws, and it's - * always better to use normal launch for small instances. + * Since NGG fast launch is enabled by VGT_SHADER_STAGES_EN, which causes a context roll, + * which decreases performance, decrease the frequency of switching it on/off using + * a high vertex count threshold. */ - if (!HAS_TESS && ngg_culling && min_direct_count >= 64 && + if (!HAS_TESS && ngg_culling && total_direct_count >= 8000 && !(sctx->screen->debug_flags & DBG(NO_FAST_LAUNCH))) { if (prim == PIPE_PRIM_TRIANGLES && !index_size) { ngg_culling |= SI_NGG_CULL_GS_FAST_LAUNCH_TRI_LIST; -- 2.7.4