From 1ac009473bab32a304beb4f115fbae2514824a06 Mon Sep 17 00:00:00 2001 From: Kristian Høgsberg Date: Thu, 20 Oct 2011 15:05:11 -0400 Subject: debug: Print debug message when client wakes up This helps spot and remove extraneous round trips and context switches. --- src/wayland-client.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/wayland-client.c b/src/wayland-client.c index de84698..efb7fe6 100644 --- a/src/wayland-client.c +++ b/src/wayland-client.c @@ -450,6 +450,11 @@ wl_display_iterate(struct wl_display *display, uint32_t mask) } len = wl_connection_data(display->connection, mask); + + if (wl_debug && (mask & WL_DISPLAY_READABLE)) + fprintf(stderr, + "[-----------] wakeup, read %d bytes\n", len); + while (len > 0) { if (len < sizeof p) break; -- cgit v1.2.3