summaryrefslogtreecommitdiff
path: root/ace/High_Res_Timer.cpp
diff options
context:
space:
mode:
authorlevine <levine@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-10-09 04:28:21 +0000
committerlevine <levine@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-10-09 04:28:21 +0000
commit42dd6fe2be0e1e6cc5a4922baa79a4e4ebebe83b (patch)
treea8a3fda2892d9202787512110935034fb372bf2a /ace/High_Res_Timer.cpp
parenta4ea4614c5ad8a7afd8e72f3b72dafcc229f5ce5 (diff)
downloadATCD-42dd6fe2be0e1e6cc5a4922baa79a4e4ebebe83b.tar.gz
added ACE_HAS_ALPHA_TIMER support
Diffstat (limited to 'ace/High_Res_Timer.cpp')
-rw-r--r--ace/High_Res_Timer.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/ace/High_Res_Timer.cpp b/ace/High_Res_Timer.cpp
index f53034f013b..a4be3741547 100644
--- a/ace/High_Res_Timer.cpp
+++ b/ace/High_Res_Timer.cpp
@@ -16,7 +16,8 @@ ACE_ALLOC_HOOK_DEFINE(ACE_High_Res_Timer)
// For Intel platforms, a scale factor is required for
// ACE_OS::gethrtime. We'll still set this to one to prevent division
// by zero errors.
-#if (defined (ACE_HAS_PENTIUM) || defined (ACE_HAS_POWERPC_TIMER)) && \
+#if (defined (ACE_HAS_PENTIUM) || defined (ACE_HAS_POWERPC_TIMER) || \
+ defined (ACE_HAS_ALPHA_TIMER)) && \
!defined (ACE_HAS_HI_RES_TIMER)
# include "ace/Synch.h"
@@ -62,19 +63,22 @@ ACE_High_Res_Timer::get_registry_scale_factor (void)
// value.
/* static */
ACE_UINT32 ACE_High_Res_Timer::global_scale_factor_ = 1u;
-#else /* ! (ACE_HAS_PENTIUM || ACE_HAS_POWERPC_TIMER) ||
+#else /* ! (ACE_HAS_PENTIUM || ACE_HAS_POWERPC_TIMER || \
+ ACE_HAS_ALPHA_TIMER) ||
ACE_HAS_HI_RES_TIMER */
// A scale_factor of 1000 converts nanosecond ticks to microseconds.
// That is, on these platforms, 1 tick == 1 nanosecond.
/* static */
ACE_UINT32 ACE_High_Res_Timer::global_scale_factor_ = 1000u;
-#endif /* ! (ACE_HAS_PENTIUM || ACE_HAS_POWERPC_TIMER) ||
+#endif /* ! (ACE_HAS_PENTIUM || ACE_HAS_POWERPC_TIMER || \
+ ACE_HAS_ALPHA_TIMER) ||
ACE_HAS_HI_RES_TIMER */
ACE_UINT32
ACE_High_Res_Timer::global_scale_factor ()
{
-#if (defined (ACE_HAS_PENTIUM) || defined (ACE_HAS_POWERPC_TIMER)) && \
+#if (defined (ACE_HAS_PENTIUM) || defined (ACE_HAS_POWERPC_TIMER) || \
+ defined (ACE_HAS_ALPHA_TIMER)) && \
!defined (ACE_HAS_HI_RES_TIMER) && \
((defined (ACE_WIN32) && !defined (ACE_HAS_WINCE)) || \
defined (ghs) || defined (__GNUG__))
@@ -122,7 +126,8 @@ ACE_High_Res_Timer::global_scale_factor ()
ACE_High_Res_Timer::calibrate ();
}
}
-#endif /* (ACE_HAS_PENTIUM || ACE_HAS_POWERPC_TIMER) && \
+#endif /* (ACE_HAS_PENTIUM || ACE_HAS_POWERPC_TIMER || \
+ ACE_HAS_ALPHA_TIMER) && \
! ACE_HAS_HIGH_RES_TIMER &&
((WIN32 && ! WINCE) || ghs || __GNUG__) */