summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenneth Graunke <kenneth@whitecape.org>2011-11-09 21:29:54 -0800
committerKenneth Graunke <kenneth@whitecape.org>2011-11-10 22:51:20 -0800
commitd46dfed9585e7e8a26993e7f67faffe8e2641939 (patch)
tree817cb6add73da45295be0dfc5c1f33d851084973
parenta17a78a212be10fe3a9a330f3861d771e92d9074 (diff)
i965: Reorder state atom lists so all the surface state is together.
Not strictly necessary, but seems like a good idea. Suggested-by: Eric Anholt <eric@anholt.net> Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
-rw-r--r--src/mesa/drivers/dri/i965/brw_state_upload.c35
1 files changed, 19 insertions, 16 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_state_upload.c b/src/mesa/drivers/dri/i965/brw_state_upload.c
index 5a323e0fbb6..a9efc95775e 100644
--- a/src/mesa/drivers/dri/i965/brw_state_upload.c
+++ b/src/mesa/drivers/dri/i965/brw_state_upload.c
@@ -63,12 +63,13 @@ static const struct brw_tracked_state *gen4_atoms[] =
&brw_cc_vp,
&brw_cc_unit,
- /* Must be before brw_binding_table */
+ /* Surface state setup. Must come before the VS/WM unit. The binding
+ * table upload must be last.
+ */
&brw_vs_pull_constants,
&brw_wm_pull_constants,
-
- &brw_renderbuffer_surfaces, /* must do before unit */
- &brw_texture_surfaces, /* must do before unit */
+ &brw_renderbuffer_surfaces,
+ &brw_texture_surfaces,
&brw_binding_table,
&brw_samplers,
@@ -134,15 +135,16 @@ static const struct brw_tracked_state *gen6_atoms[] =
&gen6_depth_stencil_state, /* must do before cc unit */
&gen6_cc_state_pointers,
- /* Pull constants must be before brw_binding_table */
- &brw_vs_pull_constants,
- &brw_wm_pull_constants,
-
&gen6_vs_push_constants, /* Before vs_state */
&gen6_wm_push_constants, /* Before wm_state */
- &brw_renderbuffer_surfaces, /* must do before unit */
- &brw_texture_surfaces, /* must do before unit */
+ /* Surface state setup. Must come before the VS/WM unit. The binding
+ * table upload must be last.
+ */
+ &brw_vs_pull_constants,
+ &brw_wm_pull_constants,
+ &brw_renderbuffer_surfaces,
+ &brw_texture_surfaces,
&brw_binding_table,
&brw_samplers,
@@ -200,15 +202,16 @@ const struct brw_tracked_state *gen7_atoms[] =
&gen7_cc_state_pointer,
&gen7_depth_stencil_state_pointer,
- /* Pull constants must be before brw_binding_table */
- &brw_vs_pull_constants,
- &brw_wm_pull_constants,
-
&gen6_vs_push_constants, /* Before vs_state */
&gen6_wm_push_constants, /* Before wm_surfaces and constant_buffer */
- &brw_renderbuffer_surfaces, /* must do before unit */
- &brw_texture_surfaces, /* must do before unit */
+ /* Surface state setup. Must come before the VS/WM unit. The binding
+ * table upload must be last.
+ */
+ &brw_vs_pull_constants,
+ &brw_wm_pull_constants,
+ &brw_renderbuffer_surfaces,
+ &brw_texture_surfaces,
&brw_binding_table,
&gen7_samplers,