Switch to unified view

a/src/utils/smallut.h b/src/utils/smallut.h
...
...
151
/** Compute times to help with perf issues */
151
/** Compute times to help with perf issues */
152
class Chrono {
152
class Chrono {
153
 public:
153
 public:
154
  Chrono();
154
  Chrono();
155
  /** Reset origin */
155
  /** Reset origin */
156
  long restart();
156
  time_t restart();
157
  /** Snapshot current time */
157
  /** Snapshot current time */
158
  static void refnow();
158
  static void refnow();
159
  /** Get current elapsed since creation or restart
159
  /** Get current elapsed since creation or restart
160
   *
160
   *
161
   *  @param frozen give time since the last refnow call (this is to
161
   *  @param frozen give time since the last refnow call (this is to
162
   * allow for using one actual system call to get values from many
162
   * allow for using one actual system call to get values from many
163
   * chrono objects, like when examining timeouts in a queue)
163
   * chrono objects, like when examining timeouts in a queue)
164
   */
164
   */
165
  long millis(int frozen = 0);
165
  time_t millis(int frozen = 0);
166
  long ms() {return millis();}
166
  time_t ms() {return millis();}
167
  long micros(int frozen = 0);
167
  time_t micros(int frozen = 0);
168
  long long nanos(int frozen = 0);
168
  time_t nanos(int frozen = 0);
169
  float secs(int frozen = 0);
169
  double secs(int frozen = 0);
170
 private:
170
 private:
171
  long    m_secs;
171
  time_t  m_secs;
172
  long    m_nsecs; 
172
  time_t  m_nsecs; 
173
};
173
};
174
174
175
/** Temp buffer with automatic deallocation */
175
/** Temp buffer with automatic deallocation */
176
struct TempBuf {
176
struct TempBuf {
177
    TempBuf() 
177
    TempBuf()