Skip to content

Add explicit synchronization, with timelines

Simon Ser requested to merge github/fork/emersion/explicit-sync-timeline into master

This PR implements explicit synchronization. Unlike previous attempts, it uses a timeline abstraction based on drm_syncobj like Vulkan.

To inter-operate with other APIs (KMS, EGL, linux-explicit-synchronization-v1), the timeline points can be converted from/to sync_file FDs.

Test with: build/examples/explicit-sync -s weston-simple-dmabuf-egl. Use WAYLAND_DEBUG=server to check that fences are exchanged. To test the DMA-BUF sync_file extraction, use weston-simple-egl as test client (requires kernel patch).

TODO:

  • Write an example compositor
  • Extract sync_file from DMA-BUF when client doesn't support linux-explicit-synchronization-v1
  • Add wlr_texture upload synchronization
  • Figure out if this API is okay for Vulkan
  • Detect support in backends and renderers
  • Add support for EGL_EXT_image_implicit_sync_control (Mesa support still missing, but let's create a good excuse for them to add it)
  • Add support for cached state to linux-explicit-synchronization-v1
  • Documentation
  • Sanity checks (e.g. in wlr_output_commit)
  • Consider ref'counting wlr_render_timeline
  • Output cursors let's wait until output layers for this

Previous work:

Future work:

  • Multi-GPU support in the DRM backend
  • Wayland backend support
  • Vulkan renderer support
Edited by Simon Ser

Merge request reports

Loading