Module: Mesa Branch: master Commit: b65680d59fd0cd906dd15080128079b9d13eb04a URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=b65680d59fd0cd906dd15080128079b9d13eb04a
Author: Kenneth Graunke <[email protected]> Date: Mon Feb 8 18:26:57 2021 -0800 iris: Remove context from iris_create_uncompiled_shader Nothing uses the context here, just the screen. Fixes: 84a38ec1336 ("iris: Enable PIPE_CAP_SHAREABLE_SHADERS.") Reviewed-by: Anuj Phogat <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8922> --- src/gallium/drivers/iris/iris_program.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gallium/drivers/iris/iris_program.c b/src/gallium/drivers/iris/iris_program.c index 3728d5955ff..cb0295ff673 100644 --- a/src/gallium/drivers/iris/iris_program.c +++ b/src/gallium/drivers/iris/iris_program.c @@ -2193,11 +2193,10 @@ iris_get_scratch_space(struct iris_context *ice, * Actual shader compilation to assembly happens later, at first use. */ static void * -iris_create_uncompiled_shader(struct pipe_context *ctx, +iris_create_uncompiled_shader(struct iris_screen *screen, nir_shader *nir, const struct pipe_stream_output_info *so_info) { - struct iris_screen *screen = (struct iris_screen *)ctx->screen; const struct gen_device_info *devinfo = &screen->devinfo; struct iris_uncompiled_shader *ish = @@ -2249,6 +2248,7 @@ static struct iris_uncompiled_shader * iris_create_shader_state(struct pipe_context *ctx, const struct pipe_shader_state *state) { + struct iris_screen *screen = (void *) ctx->screen; struct nir_shader *nir; if (state->type == PIPE_SHADER_IR_TGSI) @@ -2256,7 +2256,7 @@ iris_create_shader_state(struct pipe_context *ctx, else nir = state->ir.nir; - return iris_create_uncompiled_shader(ctx, nir, &state->stream_output); + return iris_create_uncompiled_shader(screen, nir, &state->stream_output); } static void * @@ -2455,7 +2455,7 @@ iris_create_compute_state(struct pipe_context *ctx, nir->info.stage = MESA_SHADER_COMPUTE; struct iris_uncompiled_shader *ish = - iris_create_uncompiled_shader(ctx, nir, NULL); + iris_create_uncompiled_shader(screen, nir, NULL); ish->kernel_input_size = state->req_input_mem; ish->kernel_shared_size = state->req_local_mem; _______________________________________________ mesa-commit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-commit
