6#ifndef CRYPTOPP_HRTIMER_H
7#define CRYPTOPP_HRTIMER_H
11#if !defined(HIGHRES_TIMER_AVAILABLE) || (defined(CRYPTOPP_WIN32_AVAILABLE) && !defined(THREAD_TIMER_AVAILABLE))
15NAMESPACE_BEGIN(CryptoPP)
17#ifdef HIGHRES_TIMER_AVAILABLE
53 : m_timerUnit(unit), m_stuckAtZero(stuckAtZero), m_started(false)
54 , m_start(0), m_last(0) {}
78 double ElapsedTimeAsDouble();
89 unsigned long ElapsedTime();
95 bool m_stuckAtZero, m_started;
Measure CPU time spent executing instructions of this thread.
TimerWord GetCurrentTimerValue()
Retrieve the current timer value.
TimerWord TicksPerSecond()
Retrieve ticks per second.
ThreadUserTimer(Unit unit=TimerBase::SECONDS, bool stuckAtZero=false)
Construct a ThreadUserTimer.
TimerBase(Unit unit, bool stuckAtZero)
Construct a TimerBase.
virtual TimerWord TicksPerSecond()=0
Retrieve ticks per second.
virtual TimerWord GetCurrentTimerValue()=0
Retrieve the current timer value.
@ MILLISECONDS
Timer unit is milliseconds.
@ MICROSECONDS
Timer unit is microseconds.
@ SECONDS
Timer unit is seconds.
Timer(Unit unit=TimerBase::SECONDS, bool stuckAtZero=false)
Construct a Timer.
Library configuration file.
clock_t TimerWord
TimerWord is a clock_t.