Mesa (master): wsi/x11: Set recognizable name for WSI swapchain queue thread

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Thu Jan 7 14:32:49 UTC 2021


Module: Mesa
Branch: master
Commit: 1cce8e1101d3128703a747bec139b75d2266f4a5
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=1cce8e1101d3128703a747bec139b75d2266f4a5

Author: Michel Dänzer <mdaenzer at redhat.com>
Date:   Mon Dec 21 12:01:48 2020 +0100

wsi/x11: Set recognizable name for WSI swapchain queue thread

This makes it easier to recognize the thread e.g. in a debugger.

Reviewed-by: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8197>

---

 src/vulkan/wsi/wsi_common_x11.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/vulkan/wsi/wsi_common_x11.c b/src/vulkan/wsi/wsi_common_x11.c
index 329723736f7..d3dde5d86ef 100644
--- a/src/vulkan/wsi/wsi_common_x11.c
+++ b/src/vulkan/wsi/wsi_common_x11.c
@@ -38,6 +38,7 @@
 #include <xf86drm.h>
 #include "drm-uapi/drm_fourcc.h"
 #include "util/hash_table.h"
+#include "util/u_thread.h"
 #include "util/xmlconfig.h"
 
 #include "vk_util.h"
@@ -1141,6 +1142,9 @@ x11_manage_fifo_queues(void *state)
    VkResult result = VK_SUCCESS;
 
    assert(chain->has_present_queue);
+
+   u_thread_setname("WSI swapchain queue");
+
    while (chain->status >= 0) {
       /* We can block here unconditionally because after an image was sent to
        * the server (later on in this loop) we ensure at least one image is



More information about the mesa-commit mailing list