Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
Arcane::TimerMng Class Reference

Timer manager. More...

#include <arcane/impl/TimerMng.h>

Inheritance diagram for Arcane::TimerMng:
Collaboration diagram for Arcane::TimerMng:

Public Member Functions

 TimerMng (ITraceMng *msg)
 Constructs a timer linked to the manager mng.
void beginTimer (Timer *timer) override
 Attaches the timer timer to this manager.
Real endTimer (Timer *timer) override
 Releases the timer timer.
Real getTime (Timer *timer) override
 Time elapsed since the last call to beginTimer().
bool hasTimer (Timer *timer) override
 Indicates if the timer timer is registered.
Public Member Functions inherited from Arcane::TraceAccessor
 TraceAccessor (ITraceMng *m)
 Constructs an accessor via the trace manager m.
 TraceAccessor (const TraceAccessor &rhs)
 Copy constructor.
TraceAccessoroperator= (const TraceAccessor &rhs)
 Copy assignment operator.
virtual ~TraceAccessor ()
 Frees resources.
ITraceMngtraceMng () const
 Trace manager.
TraceMessage info () const
 Flow for an information message.
TraceMessage pinfo () const
 Flow for a parallel information message.
TraceMessage info (char category) const
 Flow for an information message of a given category.
TraceMessage pinfo (char category) const
 Flow for a parallel information message of a given category.
TraceMessage info (bool v) const
 Flow for an information message.
TraceMessage warning () const
 Flow for a warning message.
TraceMessage pwarning () const
TraceMessage error () const
 Flow for an error message.
TraceMessage perror () const
TraceMessage log () const
 Flow for a log message.
TraceMessage plog () const
 Flow for a log message.
TraceMessage logdate () const
 Flow for a log message preceded by the date.
TraceMessage fatal () const
 Flow for a fatal error message.
TraceMessage pfatal () const
 Flow for a parallel fatal error message.
TraceMessageDbg debug (Trace::eDebugLevel=Trace::Medium) const
 Flow for a debug message.
Trace::eDebugLevel configDbgLevel () const
 Debug level of the configuration file.
TraceMessage info (Int32 verbose_level) const
 Flow for an information message of a given level.
TraceMessage linfo () const
 Flow for an information message with the local information level of this instance.
TraceMessage linfo (Int32 relative_level) const
 Flow for an information message with the local information level of this instance.
void fatalMessage (const StandaloneTraceMessage &o) const
Public Member Functions inherited from Arcane::ITimerMng
virtual ~ITimerMng ()=default
 Frees resources.

Protected Member Functions

virtual Real _getRealTime ()
 Returns the real time.
virtual void _setRealTime ()
 Sets the real time.
Protected Member Functions inherited from Arcane::TraceAccessor
void _setLocalVerboseLevel (Int32 v)
Int32 _localVerboseLevel () const

Private Member Functions

void _errorInTimer (const String &msg, int retcode)

Detailed Description

Timer manager.

Warning
This class is internal to Arcane.

Definition at line 37 of file TimerMng.h.

Constructor & Destructor Documentation

◆ TimerMng()

Arcane::TimerMng::TimerMng ( ITraceMng * msg)
explicit

Constructs a timer linked to the manager mng.

Definition at line 38 of file TimerMng.cc.

References Arcane::TraceAccessor::TraceAccessor().

Referenced by Arcane::MpiTimerMng::MpiTimerMng().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ _errorInTimer()

void Arcane::TimerMng::_errorInTimer ( const String & msg,
int retcode )
private

Definition at line 103 of file TimerMng.cc.

◆ _getRealTime()

Real Arcane::TimerMng::_getRealTime ( )
protectedvirtual

Returns the real time.

Reimplemented in Arcane::MpiTimerMng, and Arcane::PapiTimerMng.

Definition at line 91 of file TimerMng.cc.

References Arcane::platform::getRealTime().

Referenced by beginTimer(), endTimer(), and getTime().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ _setRealTime()

virtual void Arcane::TimerMng::_setRealTime ( )
inlineprotectedvirtual

Sets the real time.

Reimplemented in Arcane::MpiTimerMng, and Arcane::PapiTimerMng.

Definition at line 59 of file TimerMng.h.

◆ beginTimer()

void Arcane::TimerMng::beginTimer ( Timer * timer)
overridevirtual

Attaches the timer timer to this manager.

Precondition
!timer
!hasTimer(timer)
Postcondition
hasTimer(timer)

Implements Arcane::ITimerMng.

Definition at line 50 of file TimerMng.cc.

References _getRealTime(), and Arcane::Timer::_setStartTime().

Here is the call graph for this function:

◆ endTimer()

Real Arcane::TimerMng::endTimer ( Timer * timer)
overridevirtual

Releases the timer timer.

Returns
the time elapsed since the call to beginTimer().
Precondition
!timer
hasTimer(timer)
Postcondition
!hasTimer(timer)

Implements Arcane::ITimerMng.

Definition at line 71 of file TimerMng.cc.

References _getRealTime(), and Arcane::Timer::_startTime().

Here is the call graph for this function:

◆ getTime()

Real Arcane::TimerMng::getTime ( Timer * timer)
overridevirtual

Time elapsed since the last call to beginTimer().

Precondition
!timer
hasTimer(timer)

Implements Arcane::ITimerMng.

Definition at line 60 of file TimerMng.cc.

References _getRealTime(), and Arcane::Timer::_startTime().

Here is the call graph for this function:

◆ hasTimer()

bool Arcane::TimerMng::hasTimer ( Timer * timer)
overridevirtual

Indicates if the timer timer is registered.

Precondition
!timer
Deprecated
This function will eventually be removed. Do not use it.

Implements Arcane::ITimerMng.

Definition at line 82 of file TimerMng.cc.

References Arcane::Timer::isActivated(), and Arcane::Timer::timerMng().

Here is the call graph for this function:

The documentation for this class was generated from the following files: