42 #ifndef PROFILE_HACK_H
43 #define PROFILE_HACK_H
47 namespace ProfileHackPack {
67 void set_time(
const char func_name[],
double time_secs );
162 #endif // PROFILE_HACK_H
void print_timings(std::ostream &out)
Print out the timing generated by calls to set_time().
void reset()
Stops and resets the clock if it is running.
void set_time(const char func_name[], double time_secs)
Set the name and time for a function or other section of code.
Helper class that takes care of timing.
ProfileTiming(const std::string &func_name, std::ostream *out=NULL)
ProfileTiming & operator=(const ProfileTiming &)
void start()
Starts timing if it has already not been started.
StopWatchPack::stopwatch timer_
double read()
Reads the elapsed time (sec.) and leaves the clock running.