[gtk/wip/chergert/glproto] next: add queue depth to GDK profiler metrics
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/glproto] next: add queue depth to GDK profiler metrics
- Date: Tue, 23 Feb 2021 19:35:23 +0000 (UTC)
commit 2b5d63bbc2b2bd80fc42161d2dd158622a79b1b8
Author: Christian Hergert <chergert redhat com>
Date: Tue Feb 23 11:35:12 2021 -0800
next: add queue depth to GDK profiler metrics
gsk/next/gskglcommandqueue.c | 2 ++
gsk/next/gskglcommandqueueprivate.h | 1 +
2 files changed, 3 insertions(+)
---
diff --git a/gsk/next/gskglcommandqueue.c b/gsk/next/gskglcommandqueue.c
index 10e5f2fae4..bda3f9da89 100644
--- a/gsk/next/gskglcommandqueue.c
+++ b/gsk/next/gskglcommandqueue.c
@@ -1205,6 +1205,7 @@ gsk_gl_command_queue_execute (GskGLCommandQueue *self,
gdk_profiler_set_int_counter (self->metrics.n_uniforms, n_uniforms);
gdk_profiler_set_int_counter (self->metrics.n_fbos, n_fbos);
gdk_profiler_set_int_counter (self->metrics.n_uploads, self->n_uploads);
+ gdk_profiler_set_int_counter (self->metrics.queue_depth, self->batches.len);
#ifdef G_ENABLE_DEBUG
{
@@ -1476,6 +1477,7 @@ gsk_gl_command_queue_set_profiler (GskGLCommandQueue *self,
self->metrics.n_fbos = gdk_profiler_define_int_counter ("fbos", "Number of framebuffers attached");
self->metrics.n_uniforms = gdk_profiler_define_int_counter ("uniforms", "Number of uniforms changed");
self->metrics.n_uploads = gdk_profiler_define_int_counter ("uploads", "Number of texture uploads");
+ self->metrics.queue_depth = gdk_profiler_define_int_counter ("gl-queue-depth", "Depth of GL command
batches");
}
#endif
}
diff --git a/gsk/next/gskglcommandqueueprivate.h b/gsk/next/gskglcommandqueueprivate.h
index 706a7ca03f..2fd6145fc9 100644
--- a/gsk/next/gskglcommandqueueprivate.h
+++ b/gsk/next/gskglcommandqueueprivate.h
@@ -253,6 +253,7 @@ struct _GskGLCommandQueue
guint n_fbos;
guint n_uniforms;
guint n_uploads;
+ guint queue_depth;
} metrics;
/* Counter for uploads on the frame */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]