From a529e4f7ada2c3c2de632b2f9553538b7a27c9ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Sat, 14 May 2022 02:33:30 -0400 Subject: [PATCH] radeonsi/gfx11: fix the value of VGT_GS_OUT_PRIM_TYPE at the beginning of IBs Reviewed-by: Mihai Preda Reviewed-by: Pierre-Eric Pelloux-Prayer Part-of: --- src/gallium/drivers/radeonsi/si_gfx_cs.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeonsi/si_gfx_cs.c b/src/gallium/drivers/radeonsi/si_gfx_cs.c index 5fb7eef195e..7cc718fd452 100644 --- a/src/gallium/drivers/radeonsi/si_gfx_cs.c +++ b/src/gallium/drivers/radeonsi/si_gfx_cs.c @@ -304,7 +304,11 @@ void si_set_tracked_regs_to_clear_state(struct si_context *ctx) /* Set all cleared context registers to saved. */ ctx->tracked_regs.reg_saved = BITFIELD64_MASK(SI_TRACKED_GE_PC_ALLOC); - ctx->last_gs_out_prim = 0; /* cleared by CLEAR_STATE */ + + if (ctx->gfx_level >= GFX11) + ctx->last_gs_out_prim = -1; /* uconfig register, unknown value */ + else + ctx->last_gs_out_prim = 0; /* context register cleared by CLEAR_STATE */ } void si_install_draw_wrapper(struct si_context *sctx, pipe_draw_vbo_func wrapper,