summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i965/brw_state_upload.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2008-01-09 14:08:12 -0800
committerEric Anholt <eric@anholt.net>2008-01-09 14:41:53 -0800
commitdc1608ae9d90a490ce32aa005488e3591a6d8369 (patch)
treed4c1c87e3a4e3ebedd35f7cf3c1a03d5bcc7107a /src/mesa/drivers/dri/i965/brw_state_upload.c
parent5f86ae057a645c03dc1e0c51c2fb1b2628a50e0a (diff)
[965] Replace the always_update dirty flag with BRW_NEW_BATCH.
This allows us to avoid re-emitting some state when validate_state happens multiple times per batchbuffer. Even though we flush batch per primitive currently, that may still happen already if the primitive changed (this should probably be fixed as well).
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_state_upload.c')
-rw-r--r--src/mesa/drivers/dri/i965/brw_state_upload.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_state_upload.c b/src/mesa/drivers/dri/i965/brw_state_upload.c
index 46ae49262d..1c818a2cb2 100644
--- a/src/mesa/drivers/dri/i965/brw_state_upload.c
+++ b/src/mesa/drivers/dri/i965/brw_state_upload.c
@@ -222,11 +222,10 @@ void brw_validate_state( struct brw_context *brw )
assert(atom->dirty.mesa ||
atom->dirty.brw ||
- atom->dirty.cache ||
- atom->always_update);
+ atom->dirty.cache);
assert(atom->update);
- if (check_state(state, &atom->dirty) || atom->always_update) {
+ if (check_state(state, &atom->dirty)) {
atom->update( brw );
/* emit_foo(brw); */
@@ -247,7 +246,7 @@ void brw_validate_state( struct brw_context *brw )
for (i = 0; i < Elements(atoms); i++) {
const struct brw_tracked_state *atom = brw->state.atoms[i];
- if (check_state(state, &atom->dirty) || atom->always_update)
+ if (check_state(state, &atom->dirty))
atom->update( brw );
}
}