diff options
Diffstat (limited to 'ace/High_Res_Timer.i')
-rw-r--r-- | ace/High_Res_Timer.i | 56 |
1 files changed, 0 insertions, 56 deletions
diff --git a/ace/High_Res_Timer.i b/ace/High_Res_Timer.i deleted file mode 100644 index d36e2b36815..00000000000 --- a/ace/High_Res_Timer.i +++ /dev/null @@ -1,56 +0,0 @@ -/* -*- C++ -*- */ -// $Id$ - -// High_Res_Timer.i - -ACE_INLINE int -ACE_High_Res_Timer::supported () -{ - return ACE_OS::gethrtime () != -1; -} - -ACE_INLINE -ACE_High_Res_Timer::ACE_High_Res_Timer (double scale_factor) - : scale_factor_ (scale_factor) -{ - ACE_TRACE ("ACE_High_Res_Timer::ACE_High_Res_Timer"); - this->reset (); -} - -ACE_INLINE void -ACE_High_Res_Timer::start (void) -{ - ACE_TRACE ("ACE_High_Res_Timer::start"); - this->start_ = ACE_OS::gethrtime (); -} - -ACE_INLINE void -ACE_High_Res_Timer::stop (void) -{ - ACE_TRACE ("ACE_High_Res_Timer::stop"); - this->end_ = ACE_OS::gethrtime (); -} - -ACE_INLINE void -ACE_High_Res_Timer::start_incr (void) -{ - ACE_TRACE ("ACE_High_Res_Timer::start_incr"); - this->start_incr_ = ACE_OS::gethrtime (); -} - -ACE_INLINE void -ACE_High_Res_Timer::stop_incr (void) -{ - ACE_TRACE ("ACE_High_Res_Timer::stop_incr"); - this->total_ += ACE_OS::gethrtime () - this->start_incr_; -} - -ACE_INLINE void -ACE_High_Res_Timer::elapsed_microseconds (ACE_hrtime_t &usecs) const -{ - if (scale_factor_ > 0) { - usecs = (ACE_hrtime_t) ((this->end_ - this->start_) / 1000L / scale_factor_); - } else { - usecs = (this->end_ - this->start_) / 1000L; - } -} |