gpufilter
GPU-Efficient Recursive Filtering and Summed-Area Tables
|
CPU specialization of the timer class. More...
#include <timer.h>
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. |
CPU specialization of the timer class.
CPU timer is the specialized class for CPU timing computation.
gpufilter::cpu_timer::cpu_timer | ( | size_t | data_size = 0 , |
const std::string & | unit = "" , |
||
bool | start = true |
||
) |
Constructor
[in] | data_size | Data size associated with this timer |
[in] | unit | The unit of the associated data |
[in] | start | Start this timer promptly flag |
gpufilter::cpu_timer::~cpu_timer | ( | ) |
Destructor
virtual float gpufilter::cpu_timer::do_get_elapsed | ( | ) | const [private, virtual] |
Do get time elapsed by this timer.
Implements gpufilter::base_timer.
double gpufilter::cpu_timer::get_cpu_time | ( | ) | const [private] |
Get the current CPU time.