From: Dave Airlie Date: Thu, 22 Aug 2019 01:28:40 +0000 (+1000) Subject: llvmpipe: flush on api memorybarrier. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6c2fa01b9c22dc5f4b701a4a8e701c92b6ac182d;p=mesa.git llvmpipe: flush on api memorybarrier. Until we have somewhere we can do better, just hit it with a hammer. Reviewed-by: Roland Scheidegger --- diff --git a/src/gallium/drivers/llvmpipe/lp_texture.c b/src/gallium/drivers/llvmpipe/lp_texture.c index ca15d785055..3a182b67384 100644 --- a/src/gallium/drivers/llvmpipe/lp_texture.c +++ b/src/gallium/drivers/llvmpipe/lp_texture.c @@ -768,6 +768,13 @@ llvmpipe_resource_size(const struct pipe_resource *resource) return size; } +static void +llvmpipe_memory_barrier(struct pipe_context *pipe, + unsigned flags) +{ + /* this may be an overly large hammer for this nut. */ + llvmpipe_finish(pipe, "barrier"); +} #ifdef DEBUG void @@ -824,4 +831,6 @@ llvmpipe_init_context_resource_funcs(struct pipe_context *pipe) pipe->transfer_flush_region = u_default_transfer_flush_region; pipe->buffer_subdata = u_default_buffer_subdata; pipe->texture_subdata = u_default_texture_subdata; + + pipe->memory_barrier = llvmpipe_memory_barrier; }