![]() |
|
#include <BenchTimer.h>
Public Member Functions | |
BenchTimer () | |
~BenchTimer () | |
void | reset () |
void | start () |
void | stop () |
double | value (int TIMER=CPU_TIMER) const |
double | best (int TIMER=CPU_TIMER) const |
double | worst (int TIMER=CPU_TIMER) const |
double | total (int TIMER=CPU_TIMER) const |
double | getCpuTime () const |
double | getRealTime () const |
Protected Attributes | |
Vector2d | m_starts |
Vector2d | m_times |
Vector2d | m_bests |
Vector2d | m_worsts |
Vector2d | m_totals |
Elapsed time timer keeping the best try.
On POSIX platforms we use clock_gettime with CLOCK_PROCESS_CPUTIME_ID. On Windows we use QueryPerformanceCounter
Important: on linux, you must link with -lrt
|
inline |
References reset().
Return the best elapsed time in seconds
References m_bests.
Referenced by __attribute__(), bench(), and main().
|
inline |
References e().
|
inline |
References m_bests, m_totals, and m_worsts.
Referenced by __attribute__(), bench_svd(), and BenchTimer().
|
inline |
References Eigen::CPU_TIMER, getCpuTime(), getRealTime(), m_starts, and Eigen::REAL_TIMER.
Referenced by __attribute__(), bench_svd(), and main().
|
inline |
References Eigen::CPU_TIMER, getCpuTime(), getRealTime(), m_bests, m_starts, m_times, m_totals, m_worsts, max, min, and Eigen::REAL_TIMER.
Referenced by __attribute__(), bench_svd(), and main().
Return the elapsed time in seconds between the last start/stop pair
References m_times.
Referenced by __attribute__(), bench_svd(), and main().