From 148e6c3d0dbc7bbff4fad11f74b9087beb0f3514 Mon Sep 17 00:00:00 2001 From: Gert Wollny Date: Fri, 9 Jul 2021 10:58:52 +0200 Subject: [PATCH] vrend: Don't synchronize compute shader IO interfaces Compute shader don't have in- or outputs, so don't try to sync the interfaces with the shaders that are still bound. This fixes a state leak where non-compute shaders are still bound when a compute shader is compiled. Signed-off-by: Gert Wollny Reviewed-by: Lepton Wu --- src/vrend_renderer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vrend_renderer.c b/src/vrend_renderer.c index f0993da..b804eab 100644 --- a/src/vrend_renderer.c +++ b/src/vrend_renderer.c @@ -3473,7 +3473,8 @@ static inline void vrend_fill_shader_key(struct vrend_sub_context *sub_ctx, key->tcs_present = !!sub_ctx->shaders[PIPE_SHADER_TESS_CTRL]; key->tes_present = !!sub_ctx->shaders[PIPE_SHADER_TESS_EVAL]; - vrend_sync_shader_io(sub_ctx, sel, key); + if (type != PIPE_SHADER_COMPUTE) + vrend_sync_shader_io(sub_ctx, sel, key); } static int vrend_shader_create(struct vrend_context *ctx,