radv: initial support for shared semaphores (v2)

Graphics / Mesa 3D Graphics Library / Mesa - Dave Airlie [redhat.com] - 21 July 2017 16:31 EDT

This adds support for sharing semaphores using kernel syncobjects.

Syncobj backed semaphores are used for any semaphore which is created with external flags, and when a semaphore is imported, otherwise we use the current non-kernel semaphores.

Temporary imports from syncobj fd are also available, these just override the current user until the next wait, when the temp syncobj is dropped.

v2: allocate more chunks upfront, fix off by one after previous refactor of syncobj setup, remove unnecessary null check.

eaa56ea radv: initial support for shared semaphores (v2)
src/amd/vulkan/radv_device.c | 250 +++++++++++++++++++++++---
src/amd/vulkan/radv_entrypoints_gen.py | 3 +
src/amd/vulkan/radv_private.h | 16 +-
src/amd/vulkan/radv_radeon_winsys.h | 21 ++-
src/amd/vulkan/radv_wsi.c | 30 +++-
src/amd/vulkan/winsys/amdgpu/radv_amdgpu_cs.c | 110 ++++++++----
6 files changed, 359 insertions(+), 71 deletions(-)

Upstream: cgit.freedesktop.org

  • Share