Merge branch 'js/ci-san-skip-p4-and-svn-tests' into maint-2.42
[git/debian.git] / trace2 / tr2_tgt_event.c
blob53091781eca5dc788e1f9048b0679aae41e6b11a
1 #include "git-compat-util.h"
2 #include "config.h"
3 #include "json-writer.h"
4 #include "repository.h"
5 #include "run-command.h"
6 #include "version.h"
7 #include "trace2/tr2_dst.h"
8 #include "trace2/tr2_tbuf.h"
9 #include "trace2/tr2_sid.h"
10 #include "trace2/tr2_sysenv.h"
11 #include "trace2/tr2_tgt.h"
12 #include "trace2/tr2_tls.h"
13 #include "trace2/tr2_tmr.h"
15 static struct tr2_dst tr2dst_event = {
16 .sysenv_var = TR2_SYSENV_EVENT,
20 * The version number of the JSON data generated by the EVENT target in this
21 * source file. The version should be incremented if new event types are added,
22 * if existing fields are removed, or if there are significant changes in
23 * interpretation of existing events or fields. Smaller changes, such as adding
24 * a new field to an existing event, do not require an increment to the EVENT
25 * format version.
27 #define TR2_EVENT_VERSION "3"
30 * Region nesting limit for messages written to the event target.
32 * The "region_enter" and "region_leave" messages (especially recursive
33 * messages such as those produced while diving the worktree or index)
34 * are primarily intended for the performance target during debugging.
36 * Some of the outer-most messages, however, may be of interest to the
37 * event target. Use the TR2_SYSENV_EVENT_NESTING setting to increase
38 * region details in the event target.
40 static int tr2env_event_max_nesting_levels = 2;
43 * Use the TR2_SYSENV_EVENT_BRIEF to omit the <time>, <file>, and
44 * <line> fields from most events.
46 static int tr2env_event_be_brief;
48 static int fn_init(void)
50 int want = tr2_dst_trace_want(&tr2dst_event);
51 int max_nesting;
52 int want_brief;
53 const char *nesting;
54 const char *brief;
56 if (!want)
57 return want;
59 nesting = tr2_sysenv_get(TR2_SYSENV_EVENT_NESTING);
60 if (nesting && *nesting && ((max_nesting = atoi(nesting)) > 0))
61 tr2env_event_max_nesting_levels = max_nesting;
63 brief = tr2_sysenv_get(TR2_SYSENV_EVENT_BRIEF);
64 if (brief && *brief &&
65 ((want_brief = git_parse_maybe_bool(brief)) != -1))
66 tr2env_event_be_brief = want_brief;
68 return want;
71 static void fn_term(void)
73 tr2_dst_trace_disable(&tr2dst_event);
77 * Append common key-value pairs to the currently open JSON object.
78 * "event:"<event_name>"
79 * "sid":"<sid>"
80 * "thread":"<thread_name>"
81 * "time":"<time>"
82 * "file":"<filename>"
83 * "line":<line_number>
84 * "repo":<repo_id>
86 static void event_fmt_prepare(const char *event_name, const char *file,
87 int line, const struct repository *repo,
88 struct json_writer *jw)
90 struct tr2tls_thread_ctx *ctx = tr2tls_get_self();
91 struct tr2_tbuf tb_now;
93 jw_object_string(jw, "event", event_name);
94 jw_object_string(jw, "sid", tr2_sid_get());
95 jw_object_string(jw, "thread", ctx->thread_name);
98 * In brief mode, only emit <time> on these 2 event types.
100 if (!tr2env_event_be_brief || !strcmp(event_name, "version") ||
101 !strcmp(event_name, "atexit")) {
102 tr2_tbuf_utc_datetime_extended(&tb_now);
103 jw_object_string(jw, "time", tb_now.buf);
106 if (!tr2env_event_be_brief && file && *file) {
107 jw_object_string(jw, "file", file);
108 jw_object_intmax(jw, "line", line);
111 if (repo)
112 jw_object_intmax(jw, "repo", repo->trace2_repo_id);
115 static void fn_too_many_files_fl(const char *file, int line)
117 const char *event_name = "too_many_files";
118 struct json_writer jw = JSON_WRITER_INIT;
120 jw_object_begin(&jw, 0);
121 event_fmt_prepare(event_name, file, line, NULL, &jw);
122 jw_end(&jw);
124 tr2_dst_write_line(&tr2dst_event, &jw.json);
125 jw_release(&jw);
128 static void fn_version_fl(const char *file, int line)
130 const char *event_name = "version";
131 struct json_writer jw = JSON_WRITER_INIT;
133 jw_object_begin(&jw, 0);
134 event_fmt_prepare(event_name, file, line, NULL, &jw);
135 jw_object_string(&jw, "evt", TR2_EVENT_VERSION);
136 jw_object_string(&jw, "exe", git_version_string);
137 jw_end(&jw);
139 tr2_dst_write_line(&tr2dst_event, &jw.json);
140 jw_release(&jw);
142 if (tr2dst_event.too_many_files)
143 fn_too_many_files_fl(file, line);
146 static void fn_start_fl(const char *file, int line,
147 uint64_t us_elapsed_absolute, const char **argv)
149 const char *event_name = "start";
150 struct json_writer jw = JSON_WRITER_INIT;
151 double t_abs = (double)us_elapsed_absolute / 1000000.0;
153 jw_object_begin(&jw, 0);
154 event_fmt_prepare(event_name, file, line, NULL, &jw);
155 jw_object_double(&jw, "t_abs", 6, t_abs);
156 jw_object_inline_begin_array(&jw, "argv");
157 jw_array_argv(&jw, argv);
158 jw_end(&jw);
159 jw_end(&jw);
161 tr2_dst_write_line(&tr2dst_event, &jw.json);
162 jw_release(&jw);
165 static void fn_exit_fl(const char *file, int line, uint64_t us_elapsed_absolute,
166 int code)
168 const char *event_name = "exit";
169 struct json_writer jw = JSON_WRITER_INIT;
170 double t_abs = (double)us_elapsed_absolute / 1000000.0;
172 jw_object_begin(&jw, 0);
173 event_fmt_prepare(event_name, file, line, NULL, &jw);
174 jw_object_double(&jw, "t_abs", 6, t_abs);
175 jw_object_intmax(&jw, "code", code);
176 jw_end(&jw);
178 tr2_dst_write_line(&tr2dst_event, &jw.json);
179 jw_release(&jw);
182 static void fn_signal(uint64_t us_elapsed_absolute, int signo)
184 const char *event_name = "signal";
185 struct json_writer jw = JSON_WRITER_INIT;
186 double t_abs = (double)us_elapsed_absolute / 1000000.0;
188 jw_object_begin(&jw, 0);
189 event_fmt_prepare(event_name, __FILE__, __LINE__, NULL, &jw);
190 jw_object_double(&jw, "t_abs", 6, t_abs);
191 jw_object_intmax(&jw, "signo", signo);
192 jw_end(&jw);
194 tr2_dst_write_line(&tr2dst_event, &jw.json);
195 jw_release(&jw);
198 static void fn_atexit(uint64_t us_elapsed_absolute, int code)
200 const char *event_name = "atexit";
201 struct json_writer jw = JSON_WRITER_INIT;
202 double t_abs = (double)us_elapsed_absolute / 1000000.0;
204 jw_object_begin(&jw, 0);
205 event_fmt_prepare(event_name, __FILE__, __LINE__, NULL, &jw);
206 jw_object_double(&jw, "t_abs", 6, t_abs);
207 jw_object_intmax(&jw, "code", code);
208 jw_end(&jw);
210 tr2_dst_write_line(&tr2dst_event, &jw.json);
211 jw_release(&jw);
214 static void maybe_add_string_va(struct json_writer *jw, const char *field_name,
215 const char *fmt, va_list ap)
217 if (fmt && *fmt) {
218 va_list copy_ap;
219 struct strbuf buf = STRBUF_INIT;
221 va_copy(copy_ap, ap);
222 strbuf_vaddf(&buf, fmt, copy_ap);
223 va_end(copy_ap);
225 jw_object_string(jw, field_name, buf.buf);
226 strbuf_release(&buf);
227 return;
231 static void fn_error_va_fl(const char *file, int line, const char *fmt,
232 va_list ap)
234 const char *event_name = "error";
235 struct json_writer jw = JSON_WRITER_INIT;
237 jw_object_begin(&jw, 0);
238 event_fmt_prepare(event_name, file, line, NULL, &jw);
239 maybe_add_string_va(&jw, "msg", fmt, ap);
241 * Also emit the format string as a field in case
242 * post-processors want to aggregate common error
243 * messages by type without argument fields (such
244 * as pathnames or branch names) cluttering it up.
246 if (fmt && *fmt)
247 jw_object_string(&jw, "fmt", fmt);
248 jw_end(&jw);
250 tr2_dst_write_line(&tr2dst_event, &jw.json);
251 jw_release(&jw);
254 static void fn_command_path_fl(const char *file, int line, const char *pathname)
256 const char *event_name = "cmd_path";
257 struct json_writer jw = JSON_WRITER_INIT;
259 jw_object_begin(&jw, 0);
260 event_fmt_prepare(event_name, file, line, NULL, &jw);
261 jw_object_string(&jw, "path", pathname);
262 jw_end(&jw);
264 tr2_dst_write_line(&tr2dst_event, &jw.json);
265 jw_release(&jw);
268 static void fn_command_ancestry_fl(const char *file, int line, const char **parent_names)
270 const char *event_name = "cmd_ancestry";
271 const char *parent_name = NULL;
272 struct json_writer jw = JSON_WRITER_INIT;
274 jw_object_begin(&jw, 0);
275 event_fmt_prepare(event_name, file, line, NULL, &jw);
276 jw_object_inline_begin_array(&jw, "ancestry");
278 while ((parent_name = *parent_names++))
279 jw_array_string(&jw, parent_name);
281 jw_end(&jw); /* 'ancestry' array */
282 jw_end(&jw); /* event object */
284 tr2_dst_write_line(&tr2dst_event, &jw.json);
285 jw_release(&jw);
288 static void fn_command_name_fl(const char *file, int line, const char *name,
289 const char *hierarchy)
291 const char *event_name = "cmd_name";
292 struct json_writer jw = JSON_WRITER_INIT;
294 jw_object_begin(&jw, 0);
295 event_fmt_prepare(event_name, file, line, NULL, &jw);
296 jw_object_string(&jw, "name", name);
297 if (hierarchy && *hierarchy)
298 jw_object_string(&jw, "hierarchy", hierarchy);
299 jw_end(&jw);
301 tr2_dst_write_line(&tr2dst_event, &jw.json);
302 jw_release(&jw);
305 static void fn_command_mode_fl(const char *file, int line, const char *mode)
307 const char *event_name = "cmd_mode";
308 struct json_writer jw = JSON_WRITER_INIT;
310 jw_object_begin(&jw, 0);
311 event_fmt_prepare(event_name, file, line, NULL, &jw);
312 jw_object_string(&jw, "name", mode);
313 jw_end(&jw);
315 tr2_dst_write_line(&tr2dst_event, &jw.json);
316 jw_release(&jw);
319 static void fn_alias_fl(const char *file, int line, const char *alias,
320 const char **argv)
322 const char *event_name = "alias";
323 struct json_writer jw = JSON_WRITER_INIT;
325 jw_object_begin(&jw, 0);
326 event_fmt_prepare(event_name, file, line, NULL, &jw);
327 jw_object_string(&jw, "alias", alias);
328 jw_object_inline_begin_array(&jw, "argv");
329 jw_array_argv(&jw, argv);
330 jw_end(&jw);
331 jw_end(&jw);
333 tr2_dst_write_line(&tr2dst_event, &jw.json);
334 jw_release(&jw);
337 static void fn_child_start_fl(const char *file, int line,
338 uint64_t us_elapsed_absolute,
339 const struct child_process *cmd)
341 const char *event_name = "child_start";
342 struct json_writer jw = JSON_WRITER_INIT;
344 jw_object_begin(&jw, 0);
345 event_fmt_prepare(event_name, file, line, NULL, &jw);
346 jw_object_intmax(&jw, "child_id", cmd->trace2_child_id);
347 if (cmd->trace2_hook_name) {
348 jw_object_string(&jw, "child_class", "hook");
349 jw_object_string(&jw, "hook_name", cmd->trace2_hook_name);
350 } else {
351 const char *child_class =
352 cmd->trace2_child_class ? cmd->trace2_child_class : "?";
353 jw_object_string(&jw, "child_class", child_class);
355 if (cmd->dir)
356 jw_object_string(&jw, "cd", cmd->dir);
357 jw_object_bool(&jw, "use_shell", cmd->use_shell);
358 jw_object_inline_begin_array(&jw, "argv");
359 if (cmd->git_cmd)
360 jw_array_string(&jw, "git");
361 jw_array_argv(&jw, cmd->args.v);
362 jw_end(&jw);
363 jw_end(&jw);
365 tr2_dst_write_line(&tr2dst_event, &jw.json);
366 jw_release(&jw);
369 static void fn_child_exit_fl(const char *file, int line,
370 uint64_t us_elapsed_absolute, int cid, int pid,
371 int code, uint64_t us_elapsed_child)
373 const char *event_name = "child_exit";
374 struct json_writer jw = JSON_WRITER_INIT;
375 double t_rel = (double)us_elapsed_child / 1000000.0;
377 jw_object_begin(&jw, 0);
378 event_fmt_prepare(event_name, file, line, NULL, &jw);
379 jw_object_intmax(&jw, "child_id", cid);
380 jw_object_intmax(&jw, "pid", pid);
381 jw_object_intmax(&jw, "code", code);
382 jw_object_double(&jw, "t_rel", 6, t_rel);
383 jw_end(&jw);
385 tr2_dst_write_line(&tr2dst_event, &jw.json);
387 jw_release(&jw);
390 static void fn_child_ready_fl(const char *file, int line,
391 uint64_t us_elapsed_absolute, int cid, int pid,
392 const char *ready, uint64_t us_elapsed_child)
394 const char *event_name = "child_ready";
395 struct json_writer jw = JSON_WRITER_INIT;
396 double t_rel = (double)us_elapsed_child / 1000000.0;
398 jw_object_begin(&jw, 0);
399 event_fmt_prepare(event_name, file, line, NULL, &jw);
400 jw_object_intmax(&jw, "child_id", cid);
401 jw_object_intmax(&jw, "pid", pid);
402 jw_object_string(&jw, "ready", ready);
403 jw_object_double(&jw, "t_rel", 6, t_rel);
404 jw_end(&jw);
406 tr2_dst_write_line(&tr2dst_event, &jw.json);
408 jw_release(&jw);
411 static void fn_thread_start_fl(const char *file, int line,
412 uint64_t us_elapsed_absolute)
414 const char *event_name = "thread_start";
415 struct json_writer jw = JSON_WRITER_INIT;
417 jw_object_begin(&jw, 0);
418 event_fmt_prepare(event_name, file, line, NULL, &jw);
419 jw_end(&jw);
421 tr2_dst_write_line(&tr2dst_event, &jw.json);
422 jw_release(&jw);
425 static void fn_thread_exit_fl(const char *file, int line,
426 uint64_t us_elapsed_absolute,
427 uint64_t us_elapsed_thread)
429 const char *event_name = "thread_exit";
430 struct json_writer jw = JSON_WRITER_INIT;
431 double t_rel = (double)us_elapsed_thread / 1000000.0;
433 jw_object_begin(&jw, 0);
434 event_fmt_prepare(event_name, file, line, NULL, &jw);
435 jw_object_double(&jw, "t_rel", 6, t_rel);
436 jw_end(&jw);
438 tr2_dst_write_line(&tr2dst_event, &jw.json);
439 jw_release(&jw);
442 static void fn_exec_fl(const char *file, int line, uint64_t us_elapsed_absolute,
443 int exec_id, const char *exe, const char **argv)
445 const char *event_name = "exec";
446 struct json_writer jw = JSON_WRITER_INIT;
448 jw_object_begin(&jw, 0);
449 event_fmt_prepare(event_name, file, line, NULL, &jw);
450 jw_object_intmax(&jw, "exec_id", exec_id);
451 if (exe)
452 jw_object_string(&jw, "exe", exe);
453 jw_object_inline_begin_array(&jw, "argv");
454 jw_array_argv(&jw, argv);
455 jw_end(&jw);
456 jw_end(&jw);
458 tr2_dst_write_line(&tr2dst_event, &jw.json);
459 jw_release(&jw);
462 static void fn_exec_result_fl(const char *file, int line,
463 uint64_t us_elapsed_absolute, int exec_id,
464 int code)
466 const char *event_name = "exec_result";
467 struct json_writer jw = JSON_WRITER_INIT;
469 jw_object_begin(&jw, 0);
470 event_fmt_prepare(event_name, file, line, NULL, &jw);
471 jw_object_intmax(&jw, "exec_id", exec_id);
472 jw_object_intmax(&jw, "code", code);
473 jw_end(&jw);
475 tr2_dst_write_line(&tr2dst_event, &jw.json);
476 jw_release(&jw);
479 static void fn_param_fl(const char *file, int line, const char *param,
480 const char *value, const struct key_value_info *kvi)
482 const char *event_name = "def_param";
483 struct json_writer jw = JSON_WRITER_INIT;
484 enum config_scope scope = kvi->scope;
485 const char *scope_name = config_scope_name(scope);
487 jw_object_begin(&jw, 0);
488 event_fmt_prepare(event_name, file, line, NULL, &jw);
489 jw_object_string(&jw, "scope", scope_name);
490 jw_object_string(&jw, "param", param);
491 jw_object_string(&jw, "value", value);
492 jw_end(&jw);
494 tr2_dst_write_line(&tr2dst_event, &jw.json);
495 jw_release(&jw);
498 static void fn_repo_fl(const char *file, int line,
499 const struct repository *repo)
501 const char *event_name = "def_repo";
502 struct json_writer jw = JSON_WRITER_INIT;
504 jw_object_begin(&jw, 0);
505 event_fmt_prepare(event_name, file, line, repo, &jw);
506 jw_object_string(&jw, "worktree", repo->worktree);
507 jw_end(&jw);
509 tr2_dst_write_line(&tr2dst_event, &jw.json);
510 jw_release(&jw);
513 static void fn_region_enter_printf_va_fl(const char *file, int line,
514 uint64_t us_elapsed_absolute,
515 const char *category,
516 const char *label,
517 const struct repository *repo,
518 const char *fmt, va_list ap)
520 const char *event_name = "region_enter";
521 struct tr2tls_thread_ctx *ctx = tr2tls_get_self();
522 if (ctx->nr_open_regions <= tr2env_event_max_nesting_levels) {
523 struct json_writer jw = JSON_WRITER_INIT;
525 jw_object_begin(&jw, 0);
526 event_fmt_prepare(event_name, file, line, repo, &jw);
527 jw_object_intmax(&jw, "nesting", ctx->nr_open_regions);
528 if (category)
529 jw_object_string(&jw, "category", category);
530 if (label)
531 jw_object_string(&jw, "label", label);
532 maybe_add_string_va(&jw, "msg", fmt, ap);
533 jw_end(&jw);
535 tr2_dst_write_line(&tr2dst_event, &jw.json);
536 jw_release(&jw);
540 static void fn_region_leave_printf_va_fl(
541 const char *file, int line, uint64_t us_elapsed_absolute,
542 uint64_t us_elapsed_region, const char *category, const char *label,
543 const struct repository *repo, const char *fmt, va_list ap)
545 const char *event_name = "region_leave";
546 struct tr2tls_thread_ctx *ctx = tr2tls_get_self();
547 if (ctx->nr_open_regions <= tr2env_event_max_nesting_levels) {
548 struct json_writer jw = JSON_WRITER_INIT;
549 double t_rel = (double)us_elapsed_region / 1000000.0;
551 jw_object_begin(&jw, 0);
552 event_fmt_prepare(event_name, file, line, repo, &jw);
553 jw_object_double(&jw, "t_rel", 6, t_rel);
554 jw_object_intmax(&jw, "nesting", ctx->nr_open_regions);
555 if (category)
556 jw_object_string(&jw, "category", category);
557 if (label)
558 jw_object_string(&jw, "label", label);
559 maybe_add_string_va(&jw, "msg", fmt, ap);
560 jw_end(&jw);
562 tr2_dst_write_line(&tr2dst_event, &jw.json);
563 jw_release(&jw);
567 static void fn_data_fl(const char *file, int line, uint64_t us_elapsed_absolute,
568 uint64_t us_elapsed_region, const char *category,
569 const struct repository *repo, const char *key,
570 const char *value)
572 const char *event_name = "data";
573 struct tr2tls_thread_ctx *ctx = tr2tls_get_self();
574 if (ctx->nr_open_regions <= tr2env_event_max_nesting_levels) {
575 struct json_writer jw = JSON_WRITER_INIT;
576 double t_abs = (double)us_elapsed_absolute / 1000000.0;
577 double t_rel = (double)us_elapsed_region / 1000000.0;
579 jw_object_begin(&jw, 0);
580 event_fmt_prepare(event_name, file, line, repo, &jw);
581 jw_object_double(&jw, "t_abs", 6, t_abs);
582 jw_object_double(&jw, "t_rel", 6, t_rel);
583 jw_object_intmax(&jw, "nesting", ctx->nr_open_regions);
584 jw_object_string(&jw, "category", category);
585 jw_object_string(&jw, "key", key);
586 jw_object_string(&jw, "value", value);
587 jw_end(&jw);
589 tr2_dst_write_line(&tr2dst_event, &jw.json);
590 jw_release(&jw);
594 static void fn_data_json_fl(const char *file, int line,
595 uint64_t us_elapsed_absolute,
596 uint64_t us_elapsed_region, const char *category,
597 const struct repository *repo, const char *key,
598 const struct json_writer *value)
600 const char *event_name = "data_json";
601 struct tr2tls_thread_ctx *ctx = tr2tls_get_self();
602 if (ctx->nr_open_regions <= tr2env_event_max_nesting_levels) {
603 struct json_writer jw = JSON_WRITER_INIT;
604 double t_abs = (double)us_elapsed_absolute / 1000000.0;
605 double t_rel = (double)us_elapsed_region / 1000000.0;
607 jw_object_begin(&jw, 0);
608 event_fmt_prepare(event_name, file, line, repo, &jw);
609 jw_object_double(&jw, "t_abs", 6, t_abs);
610 jw_object_double(&jw, "t_rel", 6, t_rel);
611 jw_object_intmax(&jw, "nesting", ctx->nr_open_regions);
612 jw_object_string(&jw, "category", category);
613 jw_object_string(&jw, "key", key);
614 jw_object_sub_jw(&jw, "value", value);
615 jw_end(&jw);
617 tr2_dst_write_line(&tr2dst_event, &jw.json);
618 jw_release(&jw);
622 static void fn_timer(const struct tr2_timer_metadata *meta,
623 const struct tr2_timer *timer,
624 int is_final_data)
626 const char *event_name = is_final_data ? "timer" : "th_timer";
627 struct json_writer jw = JSON_WRITER_INIT;
628 double t_total = NS_TO_SEC(timer->total_ns);
629 double t_min = NS_TO_SEC(timer->min_ns);
630 double t_max = NS_TO_SEC(timer->max_ns);
632 jw_object_begin(&jw, 0);
633 event_fmt_prepare(event_name, __FILE__, __LINE__, NULL, &jw);
634 jw_object_string(&jw, "category", meta->category);
635 jw_object_string(&jw, "name", meta->name);
636 jw_object_intmax(&jw, "intervals", timer->interval_count);
637 jw_object_double(&jw, "t_total", 6, t_total);
638 jw_object_double(&jw, "t_min", 6, t_min);
639 jw_object_double(&jw, "t_max", 6, t_max);
640 jw_end(&jw);
642 tr2_dst_write_line(&tr2dst_event, &jw.json);
643 jw_release(&jw);
646 static void fn_counter(const struct tr2_counter_metadata *meta,
647 const struct tr2_counter *counter,
648 int is_final_data)
650 const char *event_name = is_final_data ? "counter" : "th_counter";
651 struct json_writer jw = JSON_WRITER_INIT;
653 jw_object_begin(&jw, 0);
654 event_fmt_prepare(event_name, __FILE__, __LINE__, NULL, &jw);
655 jw_object_string(&jw, "category", meta->category);
656 jw_object_string(&jw, "name", meta->name);
657 jw_object_intmax(&jw, "count", counter->value);
658 jw_end(&jw);
660 tr2_dst_write_line(&tr2dst_event, &jw.json);
661 jw_release(&jw);
664 struct tr2_tgt tr2_tgt_event = {
665 .pdst = &tr2dst_event,
667 .pfn_init = fn_init,
668 .pfn_term = fn_term,
670 .pfn_version_fl = fn_version_fl,
671 .pfn_start_fl = fn_start_fl,
672 .pfn_exit_fl = fn_exit_fl,
673 .pfn_signal = fn_signal,
674 .pfn_atexit = fn_atexit,
675 .pfn_error_va_fl = fn_error_va_fl,
676 .pfn_command_path_fl = fn_command_path_fl,
677 .pfn_command_ancestry_fl = fn_command_ancestry_fl,
678 .pfn_command_name_fl = fn_command_name_fl,
679 .pfn_command_mode_fl = fn_command_mode_fl,
680 .pfn_alias_fl = fn_alias_fl,
681 .pfn_child_start_fl = fn_child_start_fl,
682 .pfn_child_exit_fl = fn_child_exit_fl,
683 .pfn_child_ready_fl = fn_child_ready_fl,
684 .pfn_thread_start_fl = fn_thread_start_fl,
685 .pfn_thread_exit_fl = fn_thread_exit_fl,
686 .pfn_exec_fl = fn_exec_fl,
687 .pfn_exec_result_fl = fn_exec_result_fl,
688 .pfn_param_fl = fn_param_fl,
689 .pfn_repo_fl = fn_repo_fl,
690 .pfn_region_enter_printf_va_fl = fn_region_enter_printf_va_fl,
691 .pfn_region_leave_printf_va_fl = fn_region_leave_printf_va_fl,
692 .pfn_data_fl = fn_data_fl,
693 .pfn_data_json_fl = fn_data_json_fl,
694 .pfn_printf_va_fl = NULL,
695 .pfn_timer = fn_timer,
696 .pfn_counter = fn_counter,