14 Timer(
const std::string &tname);
20 Timer(
const std::string &tname,
const Timer *_ratio_timer);
36 void report(
bool show_cpu)
const;
53 std::chrono::time_point<std::chrono::system_clock>
wall_start;
56 std::chrono::time_point<std::chrono::system_clock>
wall_end;
std::chrono::duration< double > wall_elapsed
Elapsed wall clock or stopwatch time.
Definition: timer.hpp:47
double cpu_end
CPU clock end time.
Definition: timer.hpp:62
void report(bool show_cpu) const
Reports the elapsed times and ratios if applicable.
Definition: timer.cpp:66
std::string timer_name
The name of the Timer.
Definition: timer.hpp:44
void resume()
Start accumulating time without resetting elapsed times.
Definition: timer.cpp:60
std::chrono::time_point< std::chrono::system_clock > wall_start
Wall clock start time.
Definition: timer.hpp:53
Timer()
Construct unnamed timer.
Definition: timer.cpp:21
std::chrono::time_point< std::chrono::system_clock > wall_end
Wall clock end time.
Definition: timer.hpp:56
void stop()
Stop accumulating times and add them to elapsed times.
Definition: timer.cpp:51
A class for recording CPU and wall clock time.
Definition: timer.hpp:10
void start()
Start accumulating time at current time, resetting elapsed times.
Definition: timer.cpp:43
double cpu_start
CPU clock start time.
Definition: timer.hpp:59
The namespace for this project.
Definition: abc_nodesel.hpp:20
const Timer * ratio_timer
For use by report to report elapsed times as ratio of other timer.
Definition: timer.hpp:69
double cpu_elapsed
Elapsed CPU time.
Definition: timer.hpp:50