50 using ChronoMap = std::map<IChronoStatSvc::ChronoTag, ChronoEntity>;
51 using StatMap = std::map<IChronoStatSvc::StatTag, StatEntity>;
75 IChronoStatSvc::ChronoTime
chronoDelta(
const IChronoStatSvc::ChronoTag& chronoTag,
76 IChronoStatSvc::ChronoType theType )
override;
81 void chronoPrint(
const IChronoStatSvc::ChronoTag& chronoTag )
override;
86 ChronoStatus
chronoStatus(
const IChronoStatSvc::ChronoTag& chronoTag )
override;
92 void stat(
const IChronoStatSvc::StatTag& statTag,
const IChronoStatSvc::StatFlag& statFlag )
override;
98 void statPrint(
const IChronoStatSvc::ChronoTag& statTag )
override;
151 auto lock = std::scoped_lock{
m_mutex };
158 std::max( std::min( l,
static_cast<int>(
MSG::FATAL ) ),
static_cast<int>(
MSG::NIL ) ) );
175 "decide if the final printout should be performed" };
177 "define the destination of the table to be printed" };
186 "decide if the final printout should be performed" };
188 "define the destination of the table to be printed" };
195 this,
"AsciiStatsOutputFile",
"",
196 "Name of the output file storing the stats. If empty, no statistics will be saved (default)" };
199 this,
"StatTableHeader",
200 " | Counter | # | sum | mean/eff^* | rms/err^* | min | max |",
201 "The header row for the output Stat-table" };
203 "Use the special format for printout of efficiency counters" };
209 using TimeMap = std::map<ChronoTag, std::vector<IChronoSvc::ChronoTime>>;
a small helper class for implementation of ChronoStatSvc service, It also could be used as some local...
The Chrono & Stat Sservice: service implements the IChronoStatSvc interface and provides the basic ch...
ChronoStatus chronoStatus(const IChronoStatSvc::ChronoTag &chronoTag) override
Implementation of IChronoStatSvc::chronoStatus.
Gaudi::Property< bool > m_statCoutFlag
Gaudi::Property< int > m_intStatPrintLevel
Gaudi::Property< std::string > m_statsOutFileName
Gaudi::Property< std::string > m_header
ServiceHandle< IInterface > m_hiveWhiteBoardSvc
ChronoStatSvc(const ChronoStatSvc &)=delete
StatusCode initialize() override
Implementation of IService::initialize()
~ChronoStatSvc() override=default
ChronoEntity * chronoStart(const IChronoStatSvc::ChronoTag &chronoTag) override
Implementation of IChronoStatSvc::chronoStart.
std::map< ChronoTag, std::vector< IChronoSvc::ChronoTime > > TimeMap
IChronoStatSvc::ChronoTime chronoDelta(const IChronoStatSvc::ChronoTag &chronoTag, IChronoStatSvc::ChronoType theType) override
Implementation of IchronoStatSvc::chronoDelta.
void saveStats()
dump the statistics into an ASCII file for offline processing
StatusCode finalize() override
Implementation of IService::finalize()
StatMap m_statEntities
stat part
const ChronoEntity * chrono(const IChronoStatSvc::ChronoTag &t) const override
extract the chrono entity for the given tag (name)
Gaudi::Property< bool > m_statTableFlag
Gaudi::Property< bool > m_chronoOrderFlag
std::mutex m_mutex
Mutex protecting m_chronoEntities.
Gaudi::Property< bool > m_chronoTableFlag
Gaudi::Property< bool > m_chronoCoutFlag
ChronoStatSvc & operator=(const ChronoStatSvc &)=delete
void stat(const IChronoStatSvc::StatTag &statTag, const IChronoStatSvc::StatFlag &statFlag) override
Implementation of IChronoStatSvc::stat add statistical information to the entity ,...
ChronoMap m_chronoEntities
chrono part
Gaudi::Property< bool > m_printUserTime
ChronoEntity & getEntity(const ChronoTag &chronoTag)
MSG::Level m_chronoPrintLevel
level of info printing
const ChronoEntity * chronoStop(const IChronoStatSvc::ChronoTag &chronoTag) override
Implementation of IChronoStatSvc::chronoStop.
static MSG::Level int2level(int l)
Gaudi::Property< bool > m_useEffFormat
MSG::Level m_statPrintLevel
level of info printing
void handle(const Incident &incident) override
Gaudi::Property< int > m_intChronoPrintLevel
ChronoStatSvc(const std::string &name, ISvcLocator *svcloc)
Default constructor.
void chronoPrint(const IChronoStatSvc::ChronoTag &chronoTag) override
Implementation of IChronoStatSvc::chronoPrint.
Gaudi::Property< std::string > m_perEventFile
void statPrint(const IChronoStatSvc::ChronoTag &statTag) override
prints (using message service) info about statistical entity, tagged by its name
std::map< IChronoStatSvc::StatTag, StatEntity > StatMap
Gaudi::Property< bool > m_printSystemTime
void merge(const ChronoStatSvc &css)
Compound assignment operator.
Gaudi::Property< bool > m_statOrderFlag
std::map< IChronoStatSvc::ChronoTag, ChronoEntity > ChronoMap
some useful typedefs
Gaudi::Property< bool > m_printEllapsedTime
Implementation of property with value of concrete type.
The IMessage is the interface implemented by the message service.
The ISvcLocator is the interface implemented by the Service Factory in the Application Manager to loc...
Base class for all Incidents (computing events).
Handle to be used in lieu of naked pointers to services.
const std::string & name() const override
Retrieve name of the service.
backward compatible StatEntity class.
This class is used for returning status codes from appropriate routines.
Base class used to extend a class implementing other interfaces.