*Backed out changeset 3be01fb200a5
--HG-- branch : trunk
This commit is contained in:
@@ -1,13 +1,18 @@
|
||||
// -*- C++ -*-
|
||||
//
|
||||
// $Id: Profile_Timer.inl 80826 2008-03-04 14:51:23Z wotte $
|
||||
|
||||
#include "ace/OS_NS_sys_time.h"
|
||||
#include "ace/OS_NS_sys_resource.h"
|
||||
#include "ace/Global_Macros.h"
|
||||
|
||||
#if (defined (ACE_HAS_PRUSAGE_T) || defined (ACE_HAS_GETRUSAGE)) && !defined (ACE_WIN32)
|
||||
|
||||
# if defined (ACE_HAS_PRUSAGE_T)
|
||||
# include "ace/OS_NS_stropts.h"
|
||||
|
||||
ACE_BEGIN_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::start (void)
|
||||
{
|
||||
@@ -16,6 +21,7 @@ ACE_Profile_Timer::start (void)
|
||||
PIOCUSAGE,
|
||||
&this->begin_usage_);
|
||||
}
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::stop (void)
|
||||
{
|
||||
@@ -25,9 +31,13 @@ ACE_Profile_Timer::stop (void)
|
||||
PIOCUSAGE,
|
||||
&this->end_usage_);
|
||||
}
|
||||
|
||||
ACE_END_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
# elif defined (ACE_HAS_GETRUSAGE)
|
||||
|
||||
ACE_BEGIN_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::start (void)
|
||||
{
|
||||
@@ -37,6 +47,7 @@ ACE_Profile_Timer::start (void)
|
||||
&this->begin_usage_);
|
||||
return 0;
|
||||
}
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::stop (void)
|
||||
{
|
||||
@@ -48,14 +59,20 @@ ACE_Profile_Timer::stop (void)
|
||||
&this->end_usage_);
|
||||
return 0;
|
||||
}
|
||||
|
||||
ACE_END_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
# endif /* ACE_HAS_PRUSAGE_T */
|
||||
|
||||
#elif defined (ACE_WIN32)
|
||||
|
||||
ACE_BEGIN_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
ACE_INLINE
|
||||
ACE_Profile_Timer::~ACE_Profile_Timer (void)
|
||||
{
|
||||
}
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::start (void)
|
||||
{
|
||||
@@ -67,6 +84,7 @@ ACE_Profile_Timer::start (void)
|
||||
this->timer_.start ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::stop (void)
|
||||
{
|
||||
@@ -78,9 +96,13 @@ ACE_Profile_Timer::stop (void)
|
||||
# endif /* ACE_HAS_GETRUSAGE */
|
||||
return 0;
|
||||
}
|
||||
|
||||
ACE_END_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
#else
|
||||
|
||||
ACE_BEGIN_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::start (void)
|
||||
{
|
||||
@@ -88,6 +110,7 @@ ACE_Profile_Timer::start (void)
|
||||
this->timer_.start ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
ACE_INLINE int
|
||||
ACE_Profile_Timer::stop (void)
|
||||
{
|
||||
@@ -95,9 +118,12 @@ ACE_Profile_Timer::stop (void)
|
||||
this->timer_.stop ();
|
||||
return 0;
|
||||
}
|
||||
|
||||
ACE_INLINE
|
||||
ACE_Profile_Timer::~ACE_Profile_Timer (void)
|
||||
{
|
||||
}
|
||||
|
||||
ACE_END_VERSIONED_NAMESPACE_DECL
|
||||
|
||||
#endif /* defined (ACE_HAS_PRUSAGE_T) || defined (ACE_HAS_GETRUSAGE) */
|
||||
|
||||
Reference in New Issue
Block a user