Add option to fetch system thread name on each prof sample

This commit is contained in:
Yinan Zhang
2020-03-24 17:53:41 -07:00
parent ccdc70a5ce
commit 2256ef8961
8 changed files with 192 additions and 58 deletions

View File

@@ -117,6 +117,7 @@ CTL_PROTO(opt_prof_final)
CTL_PROTO(opt_prof_leak)
CTL_PROTO(opt_prof_accum)
CTL_PROTO(opt_prof_recent_alloc_max)
CTL_PROTO(opt_prof_experimental_use_sys_thread_name)
CTL_PROTO(opt_zero_realloc)
CTL_PROTO(tcache_create)
CTL_PROTO(tcache_flush)
@@ -353,6 +354,8 @@ static const ctl_named_node_t opt_node[] = {
{NAME("prof_leak"), CTL(opt_prof_leak)},
{NAME("prof_accum"), CTL(opt_prof_accum)},
{NAME("prof_recent_alloc_max"), CTL(opt_prof_recent_alloc_max)},
{NAME("prof_experimental_use_sys_thread_name"),
CTL(opt_prof_experimental_use_sys_thread_name)},
{NAME("zero_realloc"), CTL(opt_zero_realloc)}
};
@@ -1829,6 +1832,8 @@ CTL_RO_NL_CGEN(config_prof, opt_prof_final, opt_prof_final, bool)
CTL_RO_NL_CGEN(config_prof, opt_prof_leak, opt_prof_leak, bool)
CTL_RO_NL_CGEN(config_prof, opt_prof_recent_alloc_max,
opt_prof_recent_alloc_max, ssize_t)
CTL_RO_NL_CGEN(config_prof, opt_prof_experimental_use_sys_thread_name,
opt_prof_experimental_use_sys_thread_name, bool)
CTL_RO_NL_GEN(opt_zero_realloc,
zero_realloc_mode_names[opt_zero_realloc_action], const char *)