mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-21 13:40:16 +01:00
radeonsi: rename tcs_tes_uses_prim_id for clarity
What we care about is whether PrimID is used while tessellation is enabled; whether it's used in TCS/TES or further down the pipeline is irrelevant. Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
parent
f4dbe2efb7
commit
4ea67c1751
3 changed files with 9 additions and 9 deletions
|
|
@ -217,7 +217,7 @@ union si_vgt_param_key {
|
|||
unsigned count_from_stream_output:1;
|
||||
unsigned line_stipple_enabled:1;
|
||||
unsigned uses_tess:1;
|
||||
unsigned tcs_tes_uses_prim_id:1;
|
||||
unsigned tess_uses_prim_id:1;
|
||||
unsigned uses_gs:1;
|
||||
unsigned _pad:32 - SI_NUM_VGT_PARAM_KEY_BITS;
|
||||
} u;
|
||||
|
|
|
|||
|
|
@ -328,7 +328,7 @@ si_get_init_multi_vgt_param(struct si_screen *sscreen,
|
|||
|
||||
if (key->u.uses_tess) {
|
||||
/* SWITCH_ON_EOI must be set if PrimID is used. */
|
||||
if (key->u.tcs_tes_uses_prim_id)
|
||||
if (key->u.tess_uses_prim_id)
|
||||
ia_switch_on_eoi = true;
|
||||
|
||||
/* Bug with tessellation and GS on Bonaire and older 2 SE chips. */
|
||||
|
|
@ -459,7 +459,7 @@ void si_init_ia_multi_vgt_param_table(struct si_context *sctx)
|
|||
key.u.count_from_stream_output = count_from_so;
|
||||
key.u.line_stipple_enabled = line_stipple;
|
||||
key.u.uses_tess = uses_tess;
|
||||
key.u.tcs_tes_uses_prim_id = tess_uses_primid;
|
||||
key.u.tess_uses_prim_id = tess_uses_primid;
|
||||
key.u.uses_gs = uses_gs;
|
||||
|
||||
sctx->ia_multi_vgt_param[key.index] =
|
||||
|
|
|
|||
|
|
@ -2126,9 +2126,9 @@ static void si_bind_vs_shader(struct pipe_context *ctx, void *state)
|
|||
r600_update_vs_writes_viewport_index(&sctx->b, si_get_vs_info(sctx));
|
||||
}
|
||||
|
||||
static void si_update_tcs_tes_uses_prim_id(struct si_context *sctx)
|
||||
static void si_update_tess_uses_prim_id(struct si_context *sctx)
|
||||
{
|
||||
sctx->ia_multi_vgt_param_key.u.tcs_tes_uses_prim_id =
|
||||
sctx->ia_multi_vgt_param_key.u.tess_uses_prim_id =
|
||||
(sctx->tes_shader.cso &&
|
||||
sctx->tes_shader.cso->info.uses_primid) ||
|
||||
(sctx->tcs_shader.cso &&
|
||||
|
|
@ -2158,7 +2158,7 @@ static void si_bind_gs_shader(struct pipe_context *ctx, void *state)
|
|||
if (enable_changed) {
|
||||
si_shader_change_notify(sctx);
|
||||
if (sctx->ia_multi_vgt_param_key.u.uses_tess)
|
||||
si_update_tcs_tes_uses_prim_id(sctx);
|
||||
si_update_tess_uses_prim_id(sctx);
|
||||
}
|
||||
r600_update_vs_writes_viewport_index(&sctx->b, si_get_vs_info(sctx));
|
||||
}
|
||||
|
|
@ -2174,7 +2174,7 @@ static void si_bind_tcs_shader(struct pipe_context *ctx, void *state)
|
|||
|
||||
sctx->tcs_shader.cso = sel;
|
||||
sctx->tcs_shader.current = sel ? sel->first_variant : NULL;
|
||||
si_update_tcs_tes_uses_prim_id(sctx);
|
||||
si_update_tess_uses_prim_id(sctx);
|
||||
sctx->do_update_shaders = true;
|
||||
|
||||
if (enable_changed)
|
||||
|
|
@ -2193,7 +2193,7 @@ static void si_bind_tes_shader(struct pipe_context *ctx, void *state)
|
|||
sctx->tes_shader.cso = sel;
|
||||
sctx->tes_shader.current = sel ? sel->first_variant : NULL;
|
||||
sctx->ia_multi_vgt_param_key.u.uses_tess = sel != NULL;
|
||||
si_update_tcs_tes_uses_prim_id(sctx);
|
||||
si_update_tess_uses_prim_id(sctx);
|
||||
sctx->do_update_shaders = true;
|
||||
si_mark_atom_dirty(sctx, &sctx->clip_regs);
|
||||
sctx->last_rast_prim = -1; /* reset this so that it gets updated */
|
||||
|
|
@ -2218,7 +2218,7 @@ static void si_bind_ps_shader(struct pipe_context *ctx, void *state)
|
|||
sctx->ps_shader.current = sel ? sel->first_variant : NULL;
|
||||
sctx->do_update_shaders = true;
|
||||
if (sel && sctx->ia_multi_vgt_param_key.u.uses_tess)
|
||||
si_update_tcs_tes_uses_prim_id(sctx);
|
||||
si_update_tess_uses_prim_id(sctx);
|
||||
si_mark_atom_dirty(sctx, &sctx->cb_render_state);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue