anv: move 3DSTATE_WM::BarycentricInterpolationMode programming to runtime
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Ivan Briano <ivan.briano@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27803>
This commit is contained in:
committed by
Marge Bot
parent
11b348a1c5
commit
355549e7b0
@@ -1682,6 +1682,7 @@ struct anv_gfx_dynamic_state {
|
||||
struct {
|
||||
uint32_t ForceThreadDispatchEnable;
|
||||
bool LineStippleEnable;
|
||||
uint32_t BarycentricInterpolationMode;
|
||||
} wm;
|
||||
|
||||
/* 3DSTATE_WM_DEPTH_STENCIL */
|
||||
|
||||
@@ -577,6 +577,14 @@ genX(cmd_buffer_flush_gfx_runtime_state)(struct anv_cmd_buffer *cmd_buffer)
|
||||
}
|
||||
}
|
||||
|
||||
if ((gfx->dirty & ANV_CMD_DIRTY_PIPELINE) ||
|
||||
(gfx->dirty & ANV_CMD_DIRTY_FS_MSAA_FLAGS)) {
|
||||
if (wm_prog_data) {
|
||||
SET(WM, wm.BarycentricInterpolationMode,
|
||||
wm_prog_data_barycentric_modes(wm_prog_data, gfx->fs_msaa_flags));
|
||||
}
|
||||
}
|
||||
|
||||
if ((gfx->dirty & (ANV_CMD_DIRTY_PIPELINE |
|
||||
ANV_CMD_DIRTY_XFB_ENABLE |
|
||||
ANV_CMD_DIRTY_OCCLUSION_QUERY_ACTIVE)) ||
|
||||
@@ -2001,6 +2009,7 @@ cmd_buffer_gfx_state_emission(struct anv_cmd_buffer *cmd_buffer)
|
||||
pipeline, partial.wm, wm) {
|
||||
SET(wm, wm, ForceThreadDispatchEnable);
|
||||
SET(wm, wm, LineStippleEnable);
|
||||
SET(wm, wm, BarycentricInterpolationMode);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1563,10 +1563,6 @@ emit_3dstate_wm(struct anv_graphics_pipeline *pipeline,
|
||||
pipeline->force_fragment_thread_dispatch =
|
||||
wm_prog_data->has_side_effects ||
|
||||
wm_prog_data->uses_kill;
|
||||
|
||||
wm.BarycentricInterpolationMode =
|
||||
wm_prog_data_barycentric_modes(wm_prog_data,
|
||||
pipeline->fs_msaa_flags);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user