iris: rework DEBUG_REEMIT
authorKenneth Graunke <kenneth@whitecape.org>
Mon, 25 Jun 2018 15:25:22 +0000 (08:25 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:07 +0000 (10:26 -0800)
don't want to have to special case this everywhere

src/gallium/drivers/iris/iris_draw.c
src/gallium/drivers/iris/iris_state.c

index 7153f7cafe3e7e4d3ca4b2575ba3462a65aebb02..f12e317e01695de3908da910e561fdb2b31e35b4 100644 (file)
@@ -37,6 +37,9 @@ iris_draw_vbo(struct pipe_context *ctx, const struct pipe_draw_info *info)
    struct iris_context *ice = (struct iris_context *) ctx;
    struct iris_batch *batch = &ice->render_batch;
 
+   if (unlikely(INTEL_DEBUG & DEBUG_REEMIT))
+      ice->state.dirty |= ~0ull;
+
    iris_batch_maybe_flush(batch, 1500);
 
    // XXX: actually do brw_cache_flush_for_*
index 67d098d601a0a9ddd3b4ce9b5850c706615ce111..5e5af76ffb6b5673d3eb30714fb1807629b9981c 100644 (file)
@@ -2333,8 +2333,7 @@ iris_restore_context_saved_bos(struct iris_context *ice,
 {
    // XXX: whack IRIS_SHADER_DIRTY_BINDING_TABLE on new batch
 
-   const uint64_t clean =
-      unlikely(INTEL_DEBUG & DEBUG_REEMIT) ? 0ull : ~ice->state.dirty;
+   const uint64_t clean = ~ice->state.dirty;
 
    if (clean & IRIS_DIRTY_CC_VIEWPORT) {
       iris_use_optional_res(batch, ice->state.last_res.cc_vp, false);
@@ -2430,8 +2429,7 @@ iris_upload_render_state(struct iris_context *ice,
                          struct iris_batch *batch,
                          const struct pipe_draw_info *draw)
 {
-   const uint64_t dirty =
-      unlikely(INTEL_DEBUG & DEBUG_REEMIT) ? ~0ull : ice->state.dirty;
+   const uint64_t dirty = ice->state.dirty;
 
    struct brw_wm_prog_data *wm_prog_data = (void *)
       ice->shaders.prog[MESA_SHADER_FRAGMENT]->prog_data;