On Tue, 8 Nov 2011 14:32:06 -0800, Kenneth Graunke <kenn...@whitecape.org> wrote: > These were only split for historical reasons: brw_wm_constants used to > be the "prepare" step, while brw_wm_constant_surface was "emit". Now > that both happen at emit time, it makes sense to combine them. > > Call the newly combined state atom "brw_wm_pull_constants" to indicate > help distinguish it from the Gen6+ atoms that handle push constants. > > Finally, remove the BRW_NEW_WM_CONSTBUF dirty bit entirely now that it's > never flagged nor used. > > Signed-off-by: Kenneth Graunke <kenn...@whitecape.org> > --- > src/mesa/drivers/dri/i965/brw_context.h | 2 - > src/mesa/drivers/dri/i965/brw_state.h | 3 +- > src/mesa/drivers/dri/i965/brw_state_upload.c | 10 +--- > src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 58 ++++----------------- > 4 files changed, 15 insertions(+), 58 deletions(-)
> @@ -357,10 +360,14 @@ brw_upload_wm_pull_constants(struct brw_context *brw) > } > drm_intel_gem_bo_unmap_gtt(brw->wm.const_bo); > > - brw->state.dirty.brw |= BRW_NEW_WM_CONSTBUF; > + intel->vtbl.create_constant_surface(brw, brw->wm.const_bo, > + params->NumParameters, > + &brw->wm.surf_offset[surf_index]); > + > + brw->state.dirty.brw |= BRW_NEW_WM_SURFACES; > } > > -const struct brw_tracked_state brw_wm_constants = { > +const struct brw_tracked_state brw_wm_pull_constants = { > .dirty = { > .mesa = (_NEW_PROGRAM_CONSTANTS), > .brw = (BRW_NEW_FRAGMENT_PROGRAM), > @@ -369,49 +376,6 @@ const struct brw_tracked_state brw_wm_constants = { > .emit = brw_upload_wm_pull_constants, > }; > -const struct brw_tracked_state brw_wm_constant_surface = { > - .dirty = { > - .mesa = 0, > - .brw = (BRW_NEW_WM_CONSTBUF | > - BRW_NEW_BATCH), > - .cache = 0 > - }, > - .emit = upload_wm_constant_surface, > -}; Looks like BRW_NEW_BATCH got lost in the refactor like in the VS refactor.
pgpAiZDVAvgWM.pgp
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev