ROOT-Sim core
3.0.0-rc.2
A General-Purpose Multi-threaded Parallel/Distributed Simulation Library
|
Statistics module. More...
#include <core/core.h>
Go to the source code of this file.
Enumerations | |
enum | stats_global_type { STATS_GLOBAL_INIT_END , STATS_GLOBAL_EVENTS_START , STATS_GLOBAL_EVENTS_END , STATS_GLOBAL_FINI_START , STATS_GLOBAL_END , STATS_GLOBAL_HR_TOTAL , STATS_GLOBAL_COUNT } |
The kind of timestamps collected during the simulation execution lifetime. More... | |
enum | stats_thread_type { STATS_MSG_PROCESSED , STATS_MSG_PROCESSED_TIME , STATS_ROLLBACK , STATS_RECOVERY_TIME , STATS_MSG_ROLLBACK , STATS_CKPT , STATS_CKPT_TIME , STATS_CKPT_SIZE , STATS_MSG_SILENT , STATS_MSG_SILENT_TIME , STATS_MSG_ANTI , STATS_REAL_TIME_GVT , STATS_COUNT } |
The kind of samples collected during a simulation run. More... | |
Functions | |
void | stats_global_time_take (enum stats_global_type this_stat) |
Take a lifetime event time value. More... | |
void | stats_global_init (void) |
Initializes the stats subsystem in the node. | |
void | stats_global_fini (void) |
Finalizes the stats subsystem in the node. More... | |
void | stats_init (void) |
Initializes the stats subsystem in the current thread. | |
void | stats_take (enum stats_thread_type this_stat, uint_fast64_t c) |
Sum a sample to a statistics value. More... | |
uint64_t | stats_retrieve (enum stats_thread_type this_stat) |
Retrieve the value of a metric of this thread. More... | |
void | stats_on_gvt (simtime_t current_gvt) |
Perform GVT related activities for the statistics subsystem. More... | |
void | stats_dump (void) |
Dump some final minimal statistics on screen. | |
Statistics module.
All the facilities to collect, gather, and dump statistics are implemented in this module.
enum stats_global_type |
The kind of timestamps collected during the simulation execution lifetime.
enum stats_thread_type |
The kind of samples collected during a simulation run.
Time samples are collected using high resolution timers
void stats_global_fini | ( | void | ) |
Finalizes the stats subsystem in the node.
When finalizing this subsystem, the master node dumps his statistics from his temporary files onto the final binary file. Then, in a distributed setting, he receives the slaves temporary files, dumping their statistics as well.
void stats_global_time_take | ( | enum stats_global_type | this_stat | ) |
Take a lifetime event time value.
this_stat | The type of event just occurred |
void stats_on_gvt | ( | simtime_t | gvt | ) |
Perform GVT related activities for the statistics subsystem.
gvt | the time value of the current GVT |
Dumps accumulated statistics to the file and resets the statistics buffer to ready up for the following processing phase
uint64_t stats_retrieve | ( | enum stats_thread_type | this_stat | ) |
Retrieve the value of a metric of this thread.
This values are computed since the end of the last GVT.
void stats_take | ( | enum stats_thread_type | this_stat, |
uint_fast64_t | c | ||
) |
Sum a sample to a statistics value.
this_stat | the statistics type to add the sample to |
c | the sample to sum |