Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

CCPUTicker Class Reference

#include <cputicker.h>

List of all members.

Public Methods

 CCPUTicker ()
 CCPUTicker (const CCPUTicker &ticker)
CCPUTicker & operator= (const CCPUTicker &ticker)
__int64 Measure ()
double GetTickCountAsSeconds () const
__int64 GetTickCount () const
BOOL IsAvailable () const

Static Public Methods

BOOL GetCPUFrequency (double &frequency, double &target_ave_dev, unsigned long interval=1000, unsigned int max_loops=20)
BOOL GetCachedCPUFrequency (double &frequency, double &target_ave_dev)

Static Protected Methods

BOOL CheckHasRDTSC ()
BOOL RunningOnNT ()

Protected Attributes

__int64 m_TickCount

Static Protected Attributes

BOOL m_bHasRDTSC = FALSE
BOOL m_bRunningOnNT = FALSE
BOOL m_bStaticsCalculated = FALSE
double m_deviation = 0
double m_freq = 0
BOOL m_bFrequencyCalculated = FALSE


Constructor & Destructor Documentation

CCPUTicker::CCPUTicker  
 

Definition at line 164 of file cputicker.cpp.

References CheckHasRDTSC(), m_bHasRDTSC, m_bRunningOnNT, m_bStaticsCalculated, m_TickCount, RunningOnNT(), and TRUE.

CCPUTicker::CCPUTicker const CCPUTicker &    ticker
 

Definition at line 177 of file cputicker.cpp.

References m_TickCount.


Member Function Documentation

BOOL CCPUTicker::CheckHasRDTSC   [static, protected]
 

Definition at line 88 of file cputicker.cpp.

References BOOL(), FALSE, and TRUE.

Referenced by CCPUTicker().

BOOL CCPUTicker::GetCachedCPUFrequency double &    frequency,
double &    target_ave_dev
[static]
 

Definition at line 353 of file cputicker.cpp.

References BOOL(), FALSE, GetCPUFrequency(), m_deviation, m_freq, and TRUE.

Referenced by TestCPU().

BOOL CCPUTicker::GetCPUFrequency double &    frequency,
double &    target_ave_dev,
unsigned long    interval = 1000,
unsigned int    max_loops = 20
[static]
 

Definition at line 298 of file cputicker.cpp.

References BOOL(), FALSE, m_bFrequencyCalculated, m_TickCount, Measure(), and TRUE.

Referenced by GetCachedCPUFrequency(), and GetTickCountAsSeconds().

__int64 CCPUTicker::GetTickCount   const [inline]
 

Definition at line 52 of file cputicker.h.

References m_TickCount.

double CCPUTicker::GetTickCountAsSeconds  
 

Definition at line 368 of file cputicker.cpp.

References BOOL(), GetCPUFrequency(), m_bFrequencyCalculated, m_deviation, m_freq, and m_TickCount.

Referenced by TestCPU().

BOOL CCPUTicker::IsAvailable  
 

Definition at line 159 of file cputicker.cpp.

References BOOL(), and m_bHasRDTSC.

Referenced by TestCPU().

__int64 CCPUTicker::Measure  
 

Definition at line 225 of file cputicker.cpp.

References m_bRunningOnNT, and m_TickCount.

Referenced by GetCPUFrequency(), and TestCPU().

CCPUTicker & CCPUTicker::operator= const CCPUTicker &    ticker [inline]
 

Definition at line 182 of file cputicker.cpp.

References m_TickCount.

BOOL CCPUTicker::RunningOnNT   [static, protected]
 

Definition at line 188 of file cputicker.cpp.

References BOOL(), FALSE, and TRUE.

Referenced by CCPUTicker().


Member Data Documentation

BOOL CCPUTicker::m_bFrequencyCalculated = FALSE [static, protected]
 

Definition at line 82 of file cputicker.cpp.

Referenced by GetCPUFrequency(), and GetTickCountAsSeconds().

BOOL CCPUTicker::m_bHasRDTSC = FALSE [static, protected]
 

Definition at line 77 of file cputicker.cpp.

Referenced by CCPUTicker(), and IsAvailable().

BOOL CCPUTicker::m_bRunningOnNT = FALSE [static, protected]
 

Definition at line 78 of file cputicker.cpp.

Referenced by CCPUTicker(), and Measure().

BOOL CCPUTicker::m_bStaticsCalculated = FALSE [static, protected]
 

Definition at line 79 of file cputicker.cpp.

Referenced by CCPUTicker().

double CCPUTicker::m_deviation = 0 [static, protected]
 

Definition at line 80 of file cputicker.cpp.

Referenced by GetCachedCPUFrequency(), and GetTickCountAsSeconds().

double CCPUTicker::m_freq = 0 [static, protected]
 

Definition at line 81 of file cputicker.cpp.

Referenced by GetCachedCPUFrequency(), and GetTickCountAsSeconds().

__int64 CCPUTicker::m_TickCount [protected]
 

Definition at line 71 of file cputicker.h.

Referenced by CCPUTicker(), GetCPUFrequency(), GetTickCount(), GetTickCountAsSeconds(), Measure(), and operator=().


The documentation for this class was generated from the following files:
Generated on Mon Nov 25 12:46:37 2002 for qadpz by doxygen1.2.18