12 #ifndef _H_SST_CORE_STATISTICS_ENGINE
13 #define _H_SST_CORE_STATISTICS_ENGINE
15 #include <sst/core/sst_types.h>
16 #include <sst/core/statapi/statfieldinfo.h>
17 #include <sst/core/unitAlgebra.h>
22 namespace Statistics {
61 void endOfSimulation();
62 void startOfSimulation();
65 void registerStatisticWithEngine(
const ComponentId_t& compId,
StatisticBase* Stat)
75 addStatisticToCompStatMap(compId, Stat, StatisticFieldInfo::UNDEFINED);
79 StatisticBase* isStatisticRegisteredWithEngine(
const std::string& compName,
const ComponentId_t& compId, std::string& statName, std::string& statSubId)
89 return isStatisticInCompStatMap(compName, compId, statName, statSubId, StatisticFieldInfo::UNDEFINED);
97 bool handleStatisticEngineClockEvent(Cycle_t CycleNum, SimTime_t timeFactor);
98 void handleStatisticEngineStartTimeEvent(SimTime_t timeFactor);
99 void handleStatisticEngineStopTimeEvent(SimTime_t timeFactor);
104 typedef std::vector<StatisticBase*> StatArray_t;
105 typedef std::map<SimTime_t, StatArray_t*> StatMap_t;
106 typedef std::map<SimTime_t, Clock*> ClockMap_t;
107 typedef std::map<SimTime_t, OneShot*> OneShotMap_t;
108 typedef std::map<ComponentId_t, StatArray_t*> CompStatMap_t;
110 StatArray_t m_EventStatisticArray;
111 StatMap_t m_PeriodicStatisticMap;
112 StatMap_t m_StartTimeMap;
113 StatMap_t m_StopTimeMap;
114 ClockMap_t m_ClockMap;
115 OneShotMap_t m_StartTimeOneShotMap;
116 OneShotMap_t m_StopTimeOneShotMap;
117 CompStatMap_t m_CompStatMap;
118 bool m_SimulationStarted;
Main control class for a SST Simulation.
Definition: simulation.h:75
Definition: statfieldinfo.h:22
A class to convert between a component's view of time and the core's view of time.
Definition: timeConverter.h:25
Main component object for the simulation.
Definition: component.h:56
TimeConverter * registerClock(std::string freq, Clock::HandlerBase *handler)
Register a handler to be called on a set frequency.
Definition: simulation.cc:896
void performStatisticOutput(StatisticBase *stat, bool endOfSimFlag=false)
Called by the Components and Subcomponent to perform a statistic Output.
Definition: statengine.cc:141
Forms the base class for statistics gathering within SST.
Definition: statbase.h:36
Functor classes for Clock handling.
Definition: clock.h:44
void performGlobalStatisticOutput(bool endOfSimFlag=false)
Called by the Components and Subcomponent to perform a global statistic Output.
Definition: statengine.cc:171
An SST core component that handles timing and event processing informing all registered Statistics to...
Definition: statengine.h:33
Performs Unit math in full precision.
Definition: unitAlgebra.h:112
fieldType_t
Supported Field Types.
Definition: statfieldinfo.h:36
Functor classes for OneShot handling.
Definition: oneshot.h:39