diff options
author | Daniel Vetter <[email protected]> | 2011-03-06 00:30:12 +0100 |
---|---|---|
committer | Daniel Vetter <[email protected]> | 2011-03-10 22:47:48 +0100 |
commit | 9070879a79c3400f08a0b136d8472a7625680ca1 (patch) | |
tree | 79990d79699bb6c8356c38f7dfba0a0155adabec /src | |
parent | b0dd74aaf730f59d5d29db71a3617ab9eb1cb62f (diff) |
i915g: streamline derived state updates of the driver pipeline
Flushing the batch/hw backend doesn't invalidate the derived state.
So kill the unnecessary function calls and add an assert in
emit_hardware_state for paranoia.
Signed-off-by: Daniel Vetter <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/i915/i915_prim_emit.c | 1 | ||||
-rw-r--r-- | src/gallium/drivers/i915/i915_prim_vbuf.c | 3 | ||||
-rw-r--r-- | src/gallium/drivers/i915/i915_state_emit.c | 2 |
3 files changed, 2 insertions, 4 deletions
diff --git a/src/gallium/drivers/i915/i915_prim_emit.c b/src/gallium/drivers/i915/i915_prim_emit.c index 276e33d4b9d..85656cd7846 100644 --- a/src/gallium/drivers/i915/i915_prim_emit.c +++ b/src/gallium/drivers/i915/i915_prim_emit.c @@ -149,7 +149,6 @@ emit_prim( struct draw_stage *stage, /* Make sure state is re-emitted after a flush: */ - i915_update_derived( i915 ); i915_emit_hardware_state( i915 ); if (!BEGIN_BATCH( 1 + nr * vertex_size / 4)) { diff --git a/src/gallium/drivers/i915/i915_prim_vbuf.c b/src/gallium/drivers/i915/i915_prim_vbuf.c index fb4c0516dd8..79db3b650eb 100644 --- a/src/gallium/drivers/i915/i915_prim_vbuf.c +++ b/src/gallium/drivers/i915/i915_prim_vbuf.c @@ -470,7 +470,6 @@ draw_arrays_fallback(struct vbuf_render *render, /* Make sure state is re-emitted after a flush: */ - i915_update_derived(i915); i915_emit_hardware_state(i915); i915->vbo_flushed = 1; @@ -519,7 +518,6 @@ i915_vbuf_render_draw_arrays(struct vbuf_render *render, /* Make sure state is re-emitted after a flush: */ - i915_update_derived(i915); i915_emit_hardware_state(i915); i915->vbo_flushed = 1; @@ -640,7 +638,6 @@ i915_vbuf_render_draw_elements(struct vbuf_render *render, /* Make sure state is re-emitted after a flush: */ - i915_update_derived(i915); i915_emit_hardware_state(i915); i915->vbo_flushed = 1; diff --git a/src/gallium/drivers/i915/i915_state_emit.c b/src/gallium/drivers/i915/i915_state_emit.c index 324a8a3e158..096aa93cf09 100644 --- a/src/gallium/drivers/i915/i915_state_emit.c +++ b/src/gallium/drivers/i915/i915_state_emit.c @@ -405,6 +405,8 @@ i915_emit_hardware_state(struct i915_context *i915 ) unsigned batch_space; uintptr_t save_ptr; + assert(i915->dirty == 0); + if (I915_DBG_ON(DBG_ATOMS)) i915_dump_hardware_dirty(i915, __FUNCTION__); |