summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i965/brw_wm.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2013-10-02 14:07:40 -0700
committerEric Anholt <eric@anholt.net>2013-10-15 10:18:42 -0700
commit3c9dc2d31b80fc73bffa1f40a91443a53229c8e2 (patch)
tree0b254db5106e9a93aad131d79c6e1399a6301db6 /src/mesa/drivers/dri/i965/brw_wm.c
parent5463b5bbbdf133986ac89fd6afdf2bc9622e3ca6 (diff)
i965: Make a brw_stage_prog_data for storing the SURF_INDEX information.
It would be nice to be able to pack our binding table so that programs that use 1 render target don't upload an extra BRW_MAX_DRAW_BUFFERS - 1 binding table entries. To do that, we need the compiled program to have information on where its surfaces go. v2: Rename size to size_bytes to be more explicit. Reviewed-by: Paul Berry <stereotype441@gmail.com>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_wm.c')
-rw-r--r--src/mesa/drivers/dri/i965/brw_wm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c
index f62e297a0e2..0fda4900aae 100644
--- a/src/mesa/drivers/dri/i965/brw_wm.c
+++ b/src/mesa/drivers/dri/i965/brw_wm.c
@@ -108,7 +108,7 @@ brw_wm_prog_data_compare(const void *in_a, const void *in_b)
const struct brw_wm_prog_data *a = in_a;
const struct brw_wm_prog_data *b = in_b;
- /* Compare all the struct up to the pointers. */
+ /* Compare all the struct (including the base) up to the pointers. */
if (memcmp(a, b, offsetof(struct brw_wm_prog_data, param)))
return false;
@@ -511,6 +511,7 @@ brw_upload_wm_prog(struct brw_context *brw)
(void) success;
assert(success);
}
+ brw->wm.base.prog_data = &brw->wm.prog_data->base;
}