radeonsi/gfx12: set DB_RENDER_OVERRIDE based on stencil state
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32653>
This commit is contained in:
@@ -605,7 +605,6 @@ gfx12_init_graphics_preamble_state(const struct ac_preamble_state *state,
|
||||
ac_pm4_set_reg(pm4, R_00B4D4_SPI_SHADER_USER_ACCUM_LSHS_3, 0);
|
||||
|
||||
/* Context registers */
|
||||
ac_pm4_set_reg(pm4, R_02800C_DB_RENDER_OVERRIDE, S_02800C_FORCE_STENCIL_READ(1));
|
||||
ac_pm4_set_reg(pm4, R_028040_DB_GL1_INTERFACE_CONTROL, 0);
|
||||
ac_pm4_set_reg(pm4, R_028048_DB_MEM_TEMPORAL,
|
||||
S_028048_Z_TEMPORAL_READ(zs_read_temporal_hint) |
|
||||
|
||||
@@ -886,6 +886,10 @@ radv_emit_graphics(struct radv_device *device, struct radeon_cmdbuf *cs)
|
||||
|
||||
if (pdev->info.gfx_level >= GFX12) {
|
||||
radeon_set_context_reg(cs, R_028000_DB_RENDER_CONTROL, 0);
|
||||
radeon_set_context_reg(cs, R_02800C_DB_RENDER_OVERRIDE,
|
||||
S_02800C_FORCE_STENCIL_READ(1) |
|
||||
/* TODO: this should be conditional based on stencil state */
|
||||
S_02800C_FORCE_STENCIL_VALID(1));
|
||||
}
|
||||
|
||||
ac_pm4_finalize(pm4);
|
||||
|
||||
Reference in New Issue
Block a user