gpufilter
GPU-Efficient Recursive Filtering and Summed-Area Tables
gpufilter::cpu_timer Class Reference

CPU specialization of the timer class. More...

#include <timer.h>

Inheritance diagram for gpufilter::cpu_timer:
gpufilter::base_timer

List of all members.

Public Member Functions

 cpu_timer (size_t data_size=0, const std::string &unit="", bool start=true)
 ~cpu_timer ()

Private Member Functions

virtual void do_start ()
 Do start this timer.
virtual void do_stop ()
 Do stop this timer.
virtual float do_get_elapsed () const
 Do get time elapsed by this timer.
double get_cpu_time () const
 Get the current CPU time.

Private Attributes

double m_start_time
 Start CPU timings.
double m_stop_time
 Stop CPU timings.

Detailed Description

CPU specialization of the timer class.

CPU timer is the specialized class for CPU timing computation.


Constructor & Destructor Documentation

gpufilter::cpu_timer::cpu_timer ( size_t  data_size = 0,
const std::string &  unit = "",
bool  start = true 
)

Constructor

Parameters:
[in]data_sizeData size associated with this timer
[in]unitThe unit of the associated data
[in]startStart this timer promptly flag
gpufilter::cpu_timer::~cpu_timer ( )

Destructor


Member Function Documentation

virtual float gpufilter::cpu_timer::do_get_elapsed ( ) const [private, virtual]

Do get time elapsed by this timer.

Returns:
Time elapsed in seconds

Implements gpufilter::base_timer.

double gpufilter::cpu_timer::get_cpu_time ( ) const [private]

Get the current CPU time.

Returns:
Current time in the CPU in seconds

The documentation for this class was generated from the following file: