summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/iris/iris_context.c
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2018-04-05 21:48:33 -0700
committerKenneth Graunke <[email protected]>2019-02-21 10:26:05 -0800
commit68229caa3824a94c34e4da53336c1aa84359e2b7 (patch)
tree031c79879122da879fae9950a32d252d48b45d94 /src/gallium/drivers/iris/iris_context.c
parent3861d24e236e51b09b2024c7c4dbb36386f359f0 (diff)
iris: more uploaders
Diffstat (limited to 'src/gallium/drivers/iris/iris_context.c')
-rw-r--r--src/gallium/drivers/iris/iris_context.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gallium/drivers/iris/iris_context.c b/src/gallium/drivers/iris/iris_context.c
index f4a912a102f..d0656cf2f22 100644
--- a/src/gallium/drivers/iris/iris_context.c
+++ b/src/gallium/drivers/iris/iris_context.c
@@ -80,6 +80,8 @@ iris_destroy_context(struct pipe_context *ctx)
u_upload_destroy(ctx->stream_uploader);
iris_destroy_program_cache(ice);
+ u_upload_destroy(ice->state.surface_uploader);
+ u_upload_destroy(ice->state.dynamic_uploader);
iris_batch_free(&ice->render_batch);
@@ -134,6 +136,13 @@ iris_create_context(struct pipe_screen *pscreen, void *priv, unsigned flags)
iris_init_program_cache(ice);
+ ice->state.surface_uploader =
+ u_upload_create(&ice->ctx, 16384, PIPE_BIND_CUSTOM, PIPE_USAGE_IMMUTABLE,
+ IRIS_RESOURCE_FLAG_SURFACE_MEMZONE);
+ ice->state.dynamic_uploader =
+ u_upload_create(&ice->ctx, 16384, PIPE_BIND_CUSTOM, PIPE_USAGE_IMMUTABLE,
+ IRIS_RESOURCE_FLAG_DYNAMIC_MEMZONE);
+
genX_call(devinfo, init_state, ice);
ice->state.init_render_context(screen, &ice->render_batch, &ice->dbg);