- // XXX: skip some if (!(batch->flags & BLORP_BATCH_NO_EMIT_DEPTH_STENCIL))
- ice->state.dirty |= ~(IRIS_DIRTY_POLYGON_STIPPLE |
- IRIS_DIRTY_LINE_STIPPLE);
-
-#if 0
- ice->state.dirty |= IRIS_DIRTY_VERTEX_BUFFERS |
- IRIS_DIRTY_COLOR_CALC_STATE |
- IRIS_DIRTY_CONSTANTS_VS |
- IRIS_DIRTY_CONSTANTS_TCS |
- IRIS_DIRTY_CONSTANTS_TES |
- IRIS_DIRTY_CONSTANTS_GS |
- IRIS_DIRTY_CONSTANTS_PS |
- IRIS_DIRTY_CONSTANTS_PS |
- IRIS_DIRTY_SAMPLER_STATES_VS |
- IRIS_DIRTY_SAMPLER_STATES_TCS |
- IRIS_DIRTY_SAMPLER_STATES_TES |
- IRIS_DIRTY_SAMPLER_STATES_GS |
- IRIS_DIRTY_SAMPLER_STATES_PS |
- IRIS_DIRTY_SAMPLER_STATES_PS |
- IRIS_DIRTY_MULTISAMPLE |
- IRIS_DIRTY_SAMPLE_MASK |
- IRIS_DIRTY_VS |
- IRIS_DIRTY_TCS |
- IRIS_DIRTY_TES |
- // IRIS_DIRTY_STREAMOUT |
- IRIS_DIRTY_GS |
- IRIS_DIRTY_CLIP |
- IRIS_DIRTY_FS |
- IRIS_DIRTY_CC_VIEWPORT |
-#endif
+
+ uint64_t skip_bits = (IRIS_DIRTY_POLYGON_STIPPLE |
+ IRIS_DIRTY_SO_BUFFERS |
+ IRIS_DIRTY_SO_DECL_LIST |
+ IRIS_DIRTY_LINE_STIPPLE |
+ IRIS_ALL_DIRTY_FOR_COMPUTE |
+ IRIS_DIRTY_SCISSOR_RECT |
+ IRIS_DIRTY_UNCOMPILED_VS |
+ IRIS_DIRTY_UNCOMPILED_TCS |
+ IRIS_DIRTY_UNCOMPILED_TES |
+ IRIS_DIRTY_UNCOMPILED_GS |
+ IRIS_DIRTY_UNCOMPILED_FS |
+ IRIS_DIRTY_VF |
+ IRIS_DIRTY_URB |
+ IRIS_DIRTY_SF_CL_VIEWPORT |
+ IRIS_DIRTY_SAMPLER_STATES_VS |
+ IRIS_DIRTY_SAMPLER_STATES_TCS |
+ IRIS_DIRTY_SAMPLER_STATES_TES |
+ IRIS_DIRTY_SAMPLER_STATES_GS);
+
+ if (!ice->shaders.uncompiled[MESA_SHADER_TESS_EVAL]) {
+ /* BLORP disabled tessellation, that's fine for the next draw */
+ skip_bits |= IRIS_DIRTY_TCS |
+ IRIS_DIRTY_TES |
+ IRIS_DIRTY_CONSTANTS_TCS |
+ IRIS_DIRTY_CONSTANTS_TES |
+ IRIS_DIRTY_BINDINGS_TCS |
+ IRIS_DIRTY_BINDINGS_TES;
+ }
+
+ if (!ice->shaders.uncompiled[MESA_SHADER_GEOMETRY]) {
+ /* BLORP disabled geometry shaders, that's fine for the next draw */
+ skip_bits |= IRIS_DIRTY_GS |
+ IRIS_DIRTY_CONSTANTS_GS |
+ IRIS_DIRTY_BINDINGS_GS;
+ }
+
+ /* we can skip flagging IRIS_DIRTY_DEPTH_BUFFER, if
+ * BLORP_BATCH_NO_EMIT_DEPTH_STENCIL is set.
+ */
+ if (blorp_batch->flags & BLORP_BATCH_NO_EMIT_DEPTH_STENCIL)
+ skip_bits |= IRIS_DIRTY_DEPTH_BUFFER;
+
+ if (!params->wm_prog_data)
+ skip_bits |= IRIS_DIRTY_BLEND_STATE | IRIS_DIRTY_PS_BLEND;
+
+ ice->state.dirty |= ~skip_bits;