stopwatch.h File Reference

#include "config_manual.h"
#include <time.h>
#include <unistd.h>
#include <sys/times.h>
#include <sys/time.h>

Include dependency graph for stopwatch.h:

Go to the source code of this file.

Classes

class  stopw_base
 base class for all the stop watches to minimize code duplication More...
class  stopwatch
class  stopwatch_u
 Stopwatch class using times() to measure userspace CPU time of ourselves and our children. More...
class  stopwatch_us
 Stopwatch class using times() to measure userspace and system CPU time of ourselves and our children. More...
class  stopwatch_e
 Stopwatch class using gettimeofday() / _ftime() / time() to measure elapsed (= wall clock) time. More...

Defines

#define CLK_TCK   ((clock_t) sysconf (_SC_CLK_TCK))
 This whole CLOCKS_PER_SEC and CLK_TCK business is terribly FUCKED UP ! We need CLK_TCK, as it gives the REAL resolution, but somebody (POSIX?) decided it should not be there.
#define LONG_MIN   (-2147483647L - 1L)
#define CPS   CLOCKS_PER_SEC


Detailed Description

Implementation of timing functions with stopwatch like semantics.

originally from Template Numerical Toolkit (TNT) for Linear Algebra

R. Pozo Applied and Computational Mathematics Division National Institute of Standards and Technology

Author:
R. Pozo

K. Garloff

Date:
98/08/19
Version:
Id
stopwatch.h,v 1.14.2.19 2006/08/14 18:43:05 garloff Exp

Definition in file stopwatch.h.


Define Documentation

#define CLK_TCK   ((clock_t) sysconf (_SC_CLK_TCK))

This whole CLOCKS_PER_SEC and CLK_TCK business is terribly FUCKED UP ! We need CLK_TCK, as it gives the REAL resolution, but somebody (POSIX?) decided it should not be there.

Therefore this crazy hack.

Todo:
REAL solution for CLK_TCK related stuff!

Definition at line 58 of file stopwatch.h.

#define CPS   CLOCKS_PER_SEC

Definition at line 78 of file stopwatch.h.

#define LONG_MIN   (-2147483647L - 1L)

Definition at line 68 of file stopwatch.h.


Generated on Wed Nov 20 09:28:37 2013 for TBCI Numerical high perf. C++ Library by  doxygen 1.5.6