From 8a0dd0af3f1a6c0310a08daf4220132ec6815b31 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Fri, 18 Oct 2019 18:02:57 -0400 Subject: [PATCH] st/mesa: update VS shader_info for NIR after lowering passes Reviewed-by: Kenneth Graunke --- src/mesa/state_tracker/st_program.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/mesa/state_tracker/st_program.c b/src/mesa/state_tracker/st_program.c index 21252492fc5..56da0c3353b 100644 --- a/src/mesa/state_tracker/st_program.c +++ b/src/mesa/state_tracker/st_program.c @@ -720,6 +720,10 @@ st_create_vp_variant(struct st_context *st, st_finalize_nir(st, &stvp->Base, stvp->shader_program, state.ir.nir); + /* Some of the lowering above may have introduced new varyings */ + nir_shader_gather_info(state.ir.nir, + nir_shader_get_entrypoint(state.ir.nir)); + vpv->driver_shader = pipe->create_vs_state(pipe, &state); /* When generating a NIR program, we usually don't have TGSI tokens. -- 2.30.2