MCPcopy Create free account
hub / github.com/ElementsProject/lightning / dump_bucket_stats

Function dump_bucket_stats

ccan/ccan/timer/timer.c:477–499  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

475
476#ifdef CCAN_TIMER_DEBUG
477static void dump_bucket_stats(FILE *fp, const struct list_head *h)
478{
479 unsigned long long min, max, num;
480 struct timer *t;
481
482 if (list_empty(h)) {
483 printf("\n");
484 return;
485 }
486
487 min = -1ULL;
488 max = 0;
489 num = 0;
490 list_for_each(h, t, list) {
491 if (t->time < min)
492 min = t->time;
493 if (t->time > max)
494 max = t->time;
495 num++;
496 }
497 fprintf(fp, " %llu (%llu-%llu)\n",
498 num, min, max);
499}
500
501void timers_dump(const struct timers *timers, FILE *fp)
502{

Callers 1

timers_dumpFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected