vkr: reduce lock contention in submit_fence and retire_fences

Closed Yiwei Zhang requested to merge zzyiwei/virglrenderer:split-sync-mutex into master

Currently those are locked under the global ctx->mutex. This MR:

  • add vkr_queue::cmd_mutex to protect VkQueue cmds between submit_cmd and submit_fence
  • split vkr_context::sync_mutex from global mutex to protect submit_fence, retire_fences and device destruction

Have the global fencing patch ready locally and tested as well.

/cc @olv @ryanneph

Edited by Yiwei Zhang

Merge request reports