mirror of
https://github.com/paulscherrerinstitute/sf_daq_buffer.git
synced 2026-10-28 08:21:28 +01:00
Add max statistics
This commit is contained in:
1 parent
bb9c6f24f5
commit
dfd6138aa0
1 file changed
+7
-1
@@ -68,6 +68,7 @@ int main (int argc, char *argv[])
|
||||
|
||||
int i_write = 0;
|
||||
size_t total_ms = 0;
|
||||
size_t max_ms = 0;
|
||||
|
||||
while (true) {
|
||||
uint64_t pulse_id = 0;
|
||||
@@ -117,11 +118,16 @@ int main (int argc, char *argv[])
|
||||
|
||||
auto ms_duration = chrono::duration_cast<chrono::milliseconds>(end_time-start_time).count();
|
||||
total_ms += ms_duration;
|
||||
if (ms_duration > max_ms) {
|
||||
max_ms = ms_duration;
|
||||
}
|
||||
|
||||
if (i_write==100) {
|
||||
cout << "assembly_ms " << total_ms / 100 << endl;
|
||||
cout << "assembly_ms " << total_ms / 100;
|
||||
cout << "max_ms " << max_ms << endl;
|
||||
i_write = 0;
|
||||
total_ms = 0;
|
||||
max_ms = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user