From 8b0426ddd48b6cf910dcfa2ff292167b00d3323a Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Tue, 9 Aug 2016 15:19:47 -0700 Subject: [PATCH] i965/blorp/gen7-8: Emit depth stencil state with CC and BLEND All three go together on SNB so let's keep them together for gen7+ as well. Signed-off-by: Jason Ekstrand Reviewed-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/gen7_blorp.c | 4 ++-- src/mesa/drivers/dri/i965/gen8_blorp.c | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/mesa/drivers/dri/i965/gen7_blorp.c b/src/mesa/drivers/dri/i965/gen7_blorp.c index ce7047b7ccd..122f37fab49 100644 --- a/src/mesa/drivers/dri/i965/gen7_blorp.c +++ b/src/mesa/drivers/dri/i965/gen7_blorp.c @@ -481,6 +481,8 @@ gen7_blorp_exec(struct brw_context *brw, gen7_blorp_emit_blend_state_pointer(brw, cc_blend_state_offset); gen7_blorp_emit_cc_state_pointer(brw, cc_state_offset); } + depthstencil_offset = gen6_blorp_emit_depth_stencil_state(brw, params); + gen7_blorp_emit_depth_stencil_state_pointers(brw, depthstencil_offset); gen7_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_VS); gen7_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_HS); @@ -488,8 +490,6 @@ gen7_blorp_exec(struct brw_context *brw, gen7_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_GS); gen7_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_PS); - depthstencil_offset = gen6_blorp_emit_depth_stencil_state(brw, params); - gen7_blorp_emit_depth_stencil_state_pointers(brw, depthstencil_offset); if (brw->use_resource_streamer) gen7_disable_hw_binding_tables(brw); if (params->wm_prog_data) { diff --git a/src/mesa/drivers/dri/i965/gen8_blorp.c b/src/mesa/drivers/dri/i965/gen8_blorp.c index d8860be4d5d..50859237308 100644 --- a/src/mesa/drivers/dri/i965/gen8_blorp.c +++ b/src/mesa/drivers/dri/i965/gen8_blorp.c @@ -521,6 +521,8 @@ gen8_blorp_exec(struct brw_context *brw, const struct brw_blorp_params *params) const uint32_t cc_state_offset = gen6_blorp_emit_cc_state(brw); gen7_blorp_emit_cc_state_pointer(brw, cc_state_offset); + gen8_blorp_emit_depth_stencil_state(brw, params); + gen8_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_VS); gen8_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_HS); gen8_blorp_disable_constant_state(brw, _3DSTATE_CONSTANT_DS); @@ -560,7 +562,6 @@ gen8_blorp_exec(struct brw_context *brw, const struct brw_blorp_params *params) gen8_blorp_emit_ps_config(brw, params); - gen8_blorp_emit_depth_stencil_state(brw, params); gen8_blorp_emit_wm_state(brw); gen8_blorp_emit_depth_disable(brw); -- 2.30.2