aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/profiling/basic_timers.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/profiling/basic_timers.c')
-rw-r--r--src/core/profiling/basic_timers.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/core/profiling/basic_timers.c b/src/core/profiling/basic_timers.c
index 866833f225..124a8d6621 100644
--- a/src/core/profiling/basic_timers.c
+++ b/src/core/profiling/basic_timers.c
@@ -45,7 +45,12 @@
#include <grpc/support/thd.h>
#include <stdio.h>
-typedef enum { BEGIN = '{', END = '}', MARK = '.' } marker_type;
+typedef enum {
+ BEGIN = '{',
+ END = '}',
+ MARK = '.',
+ IMPORTANT = '!'
+} marker_type;
typedef struct grpc_timer_entry {
grpc_precise_clock tm;
@@ -101,6 +106,13 @@ void grpc_timer_add_mark(int tag, void* id, const char* file, int line) {
}
}
+void grpc_timer_add_important_mark(int tag, void* id, const char* file,
+ int line) {
+ if (tag < GRPC_PTAG_IGNORE_THRESHOLD) {
+ grpc_timers_log_add(tag, IMPORTANT, id, file, line);
+ }
+}
+
void grpc_timer_begin(int tag, void* id, const char* file, int line) {
if (tag < GRPC_PTAG_IGNORE_THRESHOLD) {
grpc_timers_log_add(tag, BEGIN, id, file, line);