summaryrefslogtreecommitdiff
path: root/ace/High_Res_Timer.cpp
diff options
context:
space:
mode:
authornanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-01-24 05:30:34 +0000
committernanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-01-24 05:30:34 +0000
commitbbb4bc74bbb995311d80f361a9bb07b650157dbe (patch)
treeb11422ac09108f1551ca88e1be634b4d6332587f /ace/High_Res_Timer.cpp
parent0bf199ef5c6757bdf158575f320e612ffdbfe52d (diff)
downloadATCD-bbb4bc74bbb995311d80f361a9bb07b650157dbe.tar.gz
Added new elapsed_time_incr
Diffstat (limited to 'ace/High_Res_Timer.cpp')
-rw-r--r--ace/High_Res_Timer.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/ace/High_Res_Timer.cpp b/ace/High_Res_Timer.cpp
index 1b405e4e09a..520c9d4b2c6 100644
--- a/ace/High_Res_Timer.cpp
+++ b/ace/High_Res_Timer.cpp
@@ -282,7 +282,14 @@ ACE_High_Res_Timer::elapsed_time (ACE_hrtime_t &nanoseconds) const
// Please do _not_ rearrange this equation. It is carefully
// designed and tested to avoid overflow on machines that
// don't have native 64-bit ints.
- nanoseconds = (this->end_ - this->start_) * (1000u / global_scale_factor ());
+ nanoseconds = (this->end_ - this->start_) * (1000u / this->global_scale_factor ());
+}
+
+void
+ACE_High_Res_Timer::elapsed_time_incr (ACE_hrtime_t &nanoseconds) const
+{
+ // Same as above.
+ nanoseconds = this->total_ * (1000u / this->global_scale_factor ());
}
#if !defined (ACE_HAS_WINCE)