mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 15:48:36 +02:00
llvmpipe: add support for fence_server_sync.
This fixes multi-context flushes with async fs processing. Reviewed-by: Roland Scheidegger <sroland@vmware.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14923>
This commit is contained in:
parent
1318cb4c5a
commit
0dccec8e89
1 changed files with 12 additions and 0 deletions
|
|
@ -47,6 +47,7 @@
|
|||
#include "lp_query.h"
|
||||
#include "lp_setup.h"
|
||||
#include "lp_screen.h"
|
||||
#include "lp_fence.h"
|
||||
|
||||
/* This is only safe if there's just one concurrent context */
|
||||
#ifdef EMBEDDED_DEVICE
|
||||
|
|
@ -118,6 +119,16 @@ do_flush( struct pipe_context *pipe,
|
|||
llvmpipe_flush(pipe, fence, __FUNCTION__);
|
||||
}
|
||||
|
||||
static void
|
||||
llvmpipe_fence_server_sync(struct pipe_context *pipe,
|
||||
struct pipe_fence_handle *fence)
|
||||
{
|
||||
struct lp_fence *f = (struct lp_fence *)fence;
|
||||
|
||||
if (!f->issued)
|
||||
return;
|
||||
lp_fence_wait(f);
|
||||
}
|
||||
|
||||
static void
|
||||
llvmpipe_render_condition(struct pipe_context *pipe,
|
||||
|
|
@ -207,6 +218,7 @@ llvmpipe_create_context(struct pipe_screen *screen, void *priv,
|
|||
llvmpipe->pipe.render_condition = llvmpipe_render_condition;
|
||||
llvmpipe->pipe.render_condition_mem = llvmpipe_render_condition_mem;
|
||||
|
||||
llvmpipe->pipe.fence_server_sync = llvmpipe_fence_server_sync;
|
||||
llvmpipe->pipe.get_device_reset_status = llvmpipe_get_device_reset_status;
|
||||
llvmpipe_init_blend_funcs(llvmpipe);
|
||||
llvmpipe_init_clip_funcs(llvmpipe);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue