diff options
author | Alexander Larsson <alexl@redhat.com> | 2020-02-12 11:25:34 +0100 |
---|---|---|
committer | Alexander Larsson <alexl@redhat.com> | 2020-02-12 11:25:34 +0100 |
commit | 2890cd849fd7d8e0cd73ed09a6bf0494dbafc8d5 (patch) | |
tree | dbd438906d5fbacce22f1d13ecb1ffb908d5a686 /gdk/gdkprofilerprivate.h | |
parent | 01d5ad2056f9c896246219eb04ca1ae807a45768 (diff) | |
download | gtk+-2890cd849fd7d8e0cd73ed09a6bf0494dbafc8d5.tar.gz |
profiler: Add _end_mark() version of _add_mark()
These don't take a duration, instead they call g_get_monotonic_time() to
and subtract the start time for it.
Almost all our calls are like this, and this makes the callsites clearer
and avoids inlining the clock call into the call site.
Diffstat (limited to 'gdk/gdkprofilerprivate.h')
-rw-r--r-- | gdk/gdkprofilerprivate.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gdk/gdkprofilerprivate.h b/gdk/gdkprofilerprivate.h index 1c68739e0e..f06296d359 100644 --- a/gdk/gdkprofilerprivate.h +++ b/gdk/gdkprofilerprivate.h @@ -50,6 +50,13 @@ void gdk_profiler_add_markf (gint64 start, const char *name, const char *format, ...) G_GNUC_PRINTF (4, 5); +void gdk_profiler_end_mark (gint64 start, + const char *name, + const char *message); +void gdk_profiler_end_markf (gint64 start, + const char *name, + const char *format, + ...) G_GNUC_PRINTF (3, 4); guint gdk_profiler_define_counter (const char *name, const char *description); void gdk_profiler_set_counter (guint id, |