Report stats for tdatas_mtx and prof_dump_mtx
This commit is contained in:
parent
87e2400cbb
commit
39343555d6
@ -2509,6 +2509,30 @@ struct extent_hooks_s {
|
|||||||
counters</link>.</para></listitem>
|
counters</link>.</para></listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry id="stats.mutexes.prof_tdatas">
|
||||||
|
<term>
|
||||||
|
<mallctl>stats.mutexes.prof_thds_data.{counter}</mallctl>
|
||||||
|
(<type>counter specific type</type>) <literal>r-</literal>
|
||||||
|
[<option>--enable-stats</option>]
|
||||||
|
</term>
|
||||||
|
<listitem><para>Statistics on <varname>prof</varname> threads data mutex
|
||||||
|
(global scope; profiling related). <mallctl>{counter}</mallctl> is one
|
||||||
|
of the counters in <link linkend="mutex_counters">mutex profiling
|
||||||
|
counters</link>.</para></listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry id="stats.mutexes.prof_dump">
|
||||||
|
<term>
|
||||||
|
<mallctl>stats.mutexes.prof_dump.{counter}</mallctl>
|
||||||
|
(<type>counter specific type</type>) <literal>r-</literal>
|
||||||
|
[<option>--enable-stats</option>]
|
||||||
|
</term>
|
||||||
|
<listitem><para>Statistics on <varname>prof</varname> dumping mutex
|
||||||
|
(global scope; profiling related). <mallctl>{counter}</mallctl> is one
|
||||||
|
of the counters in <link linkend="mutex_counters">mutex profiling
|
||||||
|
counters</link>.</para></listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry id="stats.mutexes.reset">
|
<varlistentry id="stats.mutexes.reset">
|
||||||
<term>
|
<term>
|
||||||
<mallctl>stats.mutexes.reset</mallctl>
|
<mallctl>stats.mutexes.reset</mallctl>
|
||||||
|
@ -8,7 +8,9 @@
|
|||||||
#define MUTEX_PROF_GLOBAL_MUTEXES \
|
#define MUTEX_PROF_GLOBAL_MUTEXES \
|
||||||
OP(background_thread) \
|
OP(background_thread) \
|
||||||
OP(ctl) \
|
OP(ctl) \
|
||||||
OP(prof)
|
OP(prof) \
|
||||||
|
OP(prof_thds_data) \
|
||||||
|
OP(prof_dump)
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
#define OP(mtx) global_prof_mutex_##mtx,
|
#define OP(mtx) global_prof_mutex_##mtx,
|
||||||
|
10
src/ctl.c
10
src/ctl.c
@ -1093,8 +1093,12 @@ ctl_refresh(tsdn_t *tsdn) {
|
|||||||
malloc_mutex_unlock(tsdn, &mtx);
|
malloc_mutex_unlock(tsdn, &mtx);
|
||||||
|
|
||||||
if (config_prof && opt_prof) {
|
if (config_prof && opt_prof) {
|
||||||
READ_GLOBAL_MUTEX_PROF_DATA(global_prof_mutex_prof,
|
READ_GLOBAL_MUTEX_PROF_DATA(
|
||||||
bt2gctx_mtx);
|
global_prof_mutex_prof, bt2gctx_mtx);
|
||||||
|
READ_GLOBAL_MUTEX_PROF_DATA(
|
||||||
|
global_prof_mutex_prof_thds_data, tdatas_mtx);
|
||||||
|
READ_GLOBAL_MUTEX_PROF_DATA(
|
||||||
|
global_prof_mutex_prof_dump, prof_dump_mtx);
|
||||||
}
|
}
|
||||||
if (have_background_thread) {
|
if (have_background_thread) {
|
||||||
READ_GLOBAL_MUTEX_PROF_DATA(
|
READ_GLOBAL_MUTEX_PROF_DATA(
|
||||||
@ -2972,6 +2976,8 @@ stats_mutexes_reset_ctl(tsd_t *tsd, const size_t *mib,
|
|||||||
}
|
}
|
||||||
if (config_prof && opt_prof) {
|
if (config_prof && opt_prof) {
|
||||||
MUTEX_PROF_RESET(bt2gctx_mtx);
|
MUTEX_PROF_RESET(bt2gctx_mtx);
|
||||||
|
MUTEX_PROF_RESET(tdatas_mtx);
|
||||||
|
MUTEX_PROF_RESET(prof_dump_mtx);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user