summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/iris/iris_batch.c
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2018-06-06 11:59:17 -0700
committerKenneth Graunke <[email protected]>2019-02-21 10:26:06 -0800
commit9ea05ccf1f20691cde6911762bce8207c7283714 (patch)
tree750f9b06da700a9d7b26e4fdaa1b7f59fb75c634 /src/gallium/drivers/iris/iris_batch.c
parent26cc609927825aa72a1faa77701ac2359484084a (diff)
iris: completely rewrite binder
now we get a new one per batch, and flush if it fills up
Diffstat (limited to 'src/gallium/drivers/iris/iris_batch.c')
-rw-r--r--src/gallium/drivers/iris/iris_batch.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gallium/drivers/iris/iris_batch.c b/src/gallium/drivers/iris/iris_batch.c
index 6ee46030893..c3078d9c638 100644
--- a/src/gallium/drivers/iris/iris_batch.c
+++ b/src/gallium/drivers/iris/iris_batch.c
@@ -23,6 +23,7 @@
*/
#include "iris_batch.h"
+#include "iris_binder.h"
#include "iris_bufmgr.h"
#include "iris_context.h"
@@ -128,6 +129,8 @@ iris_init_batch(struct iris_batch *batch,
batch->validation_list =
malloc(batch->exec_array_size * sizeof(batch->validation_list[0]));
+ batch->binder.bo = NULL;
+
batch->cache.render = _mesa_hash_table_create(NULL, _mesa_hash_pointer,
_mesa_key_pointer_equal);
batch->cache.depth = _mesa_set_create(NULL, _mesa_hash_pointer,
@@ -221,6 +224,9 @@ iris_batch_reset(struct iris_batch *batch)
create_batch(batch);
assert(batch->bo->index == 0);
+ iris_destroy_binder(&batch->binder);
+ iris_init_binder(&batch->binder, batch->bo->bufmgr);
+
if (batch->state_sizes)
_mesa_hash_table_clear(batch->state_sizes, NULL);