(cherry picked from commit 2fc609a294
)
# Conflicts:
# core/src/poh_recorder.rs
Co-authored-by: Jeff Washington (jwash) <wash678@gmail.com>
This commit is contained in:
@ -159,6 +159,7 @@ pub struct PohRecorder {
|
|||||||
tick_lock_contention_us: u64,
|
tick_lock_contention_us: u64,
|
||||||
tick_overhead_us: u64,
|
tick_overhead_us: u64,
|
||||||
record_us: u64,
|
record_us: u64,
|
||||||
|
ticks_from_record: u64,
|
||||||
last_metric: Instant,
|
last_metric: Instant,
|
||||||
record_sender: Sender<Record>,
|
record_sender: Sender<Record>,
|
||||||
}
|
}
|
||||||
@ -498,6 +499,7 @@ impl PohRecorder {
|
|||||||
("flush_cache_tick_us", self.flush_cache_tick_us, i64),
|
("flush_cache_tick_us", self.flush_cache_tick_us, i64),
|
||||||
("prepare_send_us", self.prepare_send_us, i64),
|
("prepare_send_us", self.prepare_send_us, i64),
|
||||||
("send_us", self.send_us, i64),
|
("send_us", self.send_us, i64),
|
||||||
|
("ticks_from_record", self.ticks_from_record, i64),
|
||||||
("tick_overhead", self.tick_overhead_us, i64),
|
("tick_overhead", self.tick_overhead_us, i64),
|
||||||
(
|
(
|
||||||
"record_lock_contention",
|
"record_lock_contention",
|
||||||
@ -514,6 +516,7 @@ impl PohRecorder {
|
|||||||
self.flush_cache_tick_us = 0;
|
self.flush_cache_tick_us = 0;
|
||||||
self.prepare_send_us = 0;
|
self.prepare_send_us = 0;
|
||||||
self.send_us = 0;
|
self.send_us = 0;
|
||||||
|
self.ticks_from_record = 0;
|
||||||
self.last_metric = Instant::now();
|
self.last_metric = Instant::now();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -567,6 +570,7 @@ impl PohRecorder {
|
|||||||
}
|
}
|
||||||
// record() might fail if the next PoH hash needs to be a tick. But that's ok, tick()
|
// record() might fail if the next PoH hash needs to be a tick. But that's ok, tick()
|
||||||
// and re-record()
|
// and re-record()
|
||||||
|
self.ticks_from_record += 1;
|
||||||
self.tick();
|
self.tick();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -618,6 +622,7 @@ impl PohRecorder {
|
|||||||
tick_lock_contention_us: 0,
|
tick_lock_contention_us: 0,
|
||||||
record_us: 0,
|
record_us: 0,
|
||||||
tick_overhead_us: 0,
|
tick_overhead_us: 0,
|
||||||
|
ticks_from_record: 0,
|
||||||
last_metric: Instant::now(),
|
last_metric: Instant::now(),
|
||||||
record_sender,
|
record_sender,
|
||||||
},
|
},
|
||||||
|
Reference in New Issue
Block a user