radeonsi: emit_msaa_sample_locs packets optimization

Remembering latest states of registers to eliminate redunant SET_CONTEXT_REG packets

Signed-off-by: Sonny Jiang <sonny.jiang@amd.com>
Signed-off-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Sonny Jiang 2018-06-07 12:13:51 -04:00 committed by Marek Olšák
parent a1b4b00ce2
commit 06b47005d3
2 changed files with 6 additions and 2 deletions

View file

@ -3250,7 +3250,9 @@ static void si_emit_msaa_sample_locs(struct si_context *sctx)
rs && !rs->multisample_enable) rs && !rs->multisample_enable)
small_prim_filter_cntl &= C_028830_SMALL_PRIM_FILTER_ENABLE; small_prim_filter_cntl &= C_028830_SMALL_PRIM_FILTER_ENABLE;
radeon_set_context_reg(cs, R_028830_PA_SU_SMALL_PRIM_FILTER_CNTL, radeon_opt_set_context_reg(sctx,
R_028830_PA_SU_SMALL_PRIM_FILTER_CNTL,
SI_TRACKED_PA_SU_SMALL_PRIM_FILTER_CNTL,
small_prim_filter_cntl); small_prim_filter_cntl);
} }
} }

View file

@ -227,6 +227,8 @@ enum si_tracked_reg {
SI_TRACKED_DB_EQAA, SI_TRACKED_DB_EQAA,
SI_TRACKED_PA_SC_MODE_CNTL_1, SI_TRACKED_PA_SC_MODE_CNTL_1,
SI_TRACKED_PA_SU_SMALL_PRIM_FILTER_CNTL,
SI_NUM_TRACKED_REGS, SI_NUM_TRACKED_REGS,
}; };