| 1122 | }; |
| 1123 | |
| 1124 | static prof_tctx_t * |
| 1125 | prof_tctx_dump_iter(prof_tctx_tree_t *tctxs, prof_tctx_t *tctx, void *opaque) { |
| 1126 | struct prof_tctx_dump_iter_arg_s *arg = |
| 1127 | (struct prof_tctx_dump_iter_arg_s *)opaque; |
| 1128 | |
| 1129 | malloc_mutex_assert_owner(arg->tsdn, tctx->gctx->lock); |
| 1130 | |
| 1131 | switch (tctx->state) { |
| 1132 | case prof_tctx_state_initializing: |
| 1133 | case prof_tctx_state_nominal: |
| 1134 | /* Not captured by this dump. */ |
| 1135 | break; |
| 1136 | case prof_tctx_state_dumping: |
| 1137 | case prof_tctx_state_purgatory: |
| 1138 | if (prof_dump_printf(arg->propagate_err, |
| 1139 | " t%"FMTu64": %"FMTu64": %"FMTu64" [%"FMTu64": " |
| 1140 | "%"FMTu64"]\n", tctx->thr_uid, tctx->dump_cnts.curobjs, |
| 1141 | tctx->dump_cnts.curbytes, tctx->dump_cnts.accumobjs, |
| 1142 | tctx->dump_cnts.accumbytes)) { |
| 1143 | return tctx; |
| 1144 | } |
| 1145 | break; |
| 1146 | default: |
| 1147 | not_reached(); |
| 1148 | } |
| 1149 | return NULL; |
| 1150 | } |
| 1151 | |
| 1152 | static prof_tctx_t * |
| 1153 | prof_tctx_finish_iter(prof_tctx_tree_t *tctxs, prof_tctx_t *tctx, void *arg) { |
nothing calls this directly
no test coverage detected