mesa/src/gallium/drivers/virgl
Marek Olšák 27dcb46629 gallium: add take_ownership param into set_vertex_buffers to eliminate atomics
There are a few places (mainly u_threaded_context) that do:
   set_vertex_buffers(...);
   for (i = 0; i < count; i++)
      pipe_resource_reference(&buffers[i].resource.buffer, NULL);

set_vertex_buffers increments the reference counts while the loop
decrements them.

This commit eliminates those reference count changes by adding a parameter
into set_vertex_buffers that tells the callee to accept all buffers
without incrementing the reference counts.

AMD Zen benefits from this because it has slow atomics if they come from
different CCXs.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8298>
2021-01-27 23:53:35 +00:00
..
tests meson: add idep_mesautil to components using simple_mtx.h 2020-11-24 18:13:07 -08:00
Android.mk android: gallium/virgl: cleanup virgl_driinfo.h gen rules 2020-10-01 22:37:26 +02:00
Makefile.sources virgl: move protocol headers to a common place 2020-08-21 18:38:44 +00:00
meson.build meson: add idep_mesautil to components using simple_mtx.h 2020-11-24 18:13:07 -08:00
virgl_buffer.c virgl: support PIPE_CAP_BUFFER_MAP_PERSISTENT_COHERENT 2020-10-01 16:56:37 -07:00
virgl_context.c gallium: add take_ownership param into set_vertex_buffers to eliminate atomics 2021-01-27 23:53:35 +00:00
virgl_context.h virgl: Use virgl_staging_mgr 2019-06-28 04:30:02 +00:00
virgl_driinfo.h.in virgl: Fix typos. 2020-12-31 18:04:44 -08:00
virgl_encode.c virgl: fix handling draw info 2021-01-04 19:22:33 -05:00
virgl_encode.h gallium: extend draw_vbo to support multi draws 2020-11-18 01:41:25 +00:00
virgl_public.h gallium/virgl: Add code path for virgl to read driconf 2019-06-20 08:50:38 +02:00
virgl_query.c virgl: Fix typos. 2020-12-31 18:04:44 -08:00
virgl_resource.c virgl: add support for VIRGL_CAP_V2_UNTYPED_RESOURCE 2021-01-22 21:25:49 +00:00
virgl_resource.h virgl: query blob mem 2020-10-01 16:56:37 -07:00
virgl_screen.c Revert "virgl: fix BGRA emulation artifacts during window resize" 2021-01-25 17:58:16 +00:00
virgl_screen.h virgl: Always enable emulated BGRA and swizzling unless specifically told not to 2020-10-26 15:01:34 +00:00
virgl_staging_mgr.c virgl: add flags to (*resource_create) callback 2020-10-01 16:15:57 -07:00
virgl_staging_mgr.h virgl: Introduce virgl_staging_mgr 2019-06-28 04:30:02 +00:00
virgl_streamout.c virgl: move protocol headers to a common place 2020-08-21 18:38:44 +00:00
virgl_texture.c gallium: rename PIPE_TRANSFER_* -> PIPE_MAP_* 2020-09-22 03:20:54 +00:00
virgl_tgsi.c virgl: use debug_printf instead of fprintf 2019-04-10 14:27:45 +02:00
virgl_transfer_queue.c virgl: move protocol headers to a common place 2020-08-21 18:38:44 +00:00
virgl_transfer_queue.h virgl: rework virgl_transfer_queue_extend 2019-07-19 18:04:37 -07:00
virgl_winsys.h virgl: add support for VIRGL_CAP_V2_UNTYPED_RESOURCE 2021-01-22 21:25:49 +00:00