[Mesa-dev] [PATCH 08/16] i965/gen7.5: Skip manual binding table upload
Abdiel Janulgue
abdiel.janulgue at linux.intel.com
Tue Oct 8 14:41:45 PDT 2013
When hardware-generated binding tables are taken into use, skip uploading
of binding tables generated manually by the driver.
Signed-off-by: Abdiel Janulgue <abdiel.janulgue at linux.intel.com>
---
src/mesa/drivers/dri/i965/brw_binding_tables.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_binding_tables.c b/src/mesa/drivers/dri/i965/brw_binding_tables.c
index afbf667..2160be8 100644
--- a/src/mesa/drivers/dri/i965/brw_binding_tables.c
+++ b/src/mesa/drivers/dri/i965/brw_binding_tables.c
@@ -95,6 +95,10 @@ brw_vs_upload_binding_table(struct brw_context *brw)
/* CACHE_NEW_VS_PROG */
const struct brw_vec4_prog_data *prog_data = &brw->vs.prog_data->base;
+ /* If resource streamer is enabled, skip manual binding table upload */
+ if (brw->has_resource_streamer)
+ return;
+
/* BRW_NEW_SURFACES and BRW_NEW_VS_CONSTBUF */
brw_upload_binding_table(brw, BRW_NEW_VS_BINDING_TABLE, stage_state,
prog_data->binding_table_size,
@@ -119,6 +123,10 @@ brw_upload_wm_binding_table(struct brw_context *brw)
{
struct brw_stage_state *stage_state = &brw->wm.base;
+ /* If resource streamer is enabled, skip manual binding table upload */
+ if (brw->has_resource_streamer)
+ return;
+
/* BRW_NEW_SURFACES and CACHE_NEW_WM_PROG */
brw_upload_binding_table(brw, BRW_NEW_PS_BINDING_TABLE, stage_state,
brw->wm.prog_data->binding_table_size,
@@ -140,8 +148,8 @@ brw_gs_upload_binding_table(struct brw_context *brw)
{
struct brw_stage_state *stage_state = &brw->gs.base;
- /* If there's no GS, skip changing anything. */
- if (!brw->gs.prog_data)
+ /* If there's no GS or RS exists, skip changing anything. */
+ if (!brw->gs.prog_data || brw->has_resource_streamer)
return;
/* CACHE_NEW_GS_PROG */
--
1.7.9.5
More information about the mesa-dev
mailing list