CMS 3D CMS Logo

ChildrenCPUTimer.h
Go to the documentation of this file.
1 #ifndef FWCore_Utilities_ChildrenCPUTimer_h
2 #define FWCore_Utilities_ChildrenCPUTimer_h
3 // -*- C++ -*-
4 //
5 // Package: Utilities
6 // Class : ChildrenCPUTimer
7 //
16 //
17 // Original Author: Chris Jones
18 // Created: Sun Apr 16 20:32:13 EDT 2006
19 //
20 
21 // system include files
22 #include <sys/time.h>
23 
24 // user include files
25 
26 // forward declarations
27 namespace edm {
29  public:
33  ChildrenCPUTimer(const ChildrenCPUTimer&) = delete;
35 
36  // ---------- const member functions ---------------------
37  double cpuTime() const;
38 
39  // ---------- static member functions --------------------
40 
41  // ---------- member functions ---------------------------
42  void start();
43  double stop(); //returns delta time
44  void reset();
45 
46  void add(double t);
47 
48  private:
49  double calculateDeltaTime() const;
50 
51  // ---------- member data --------------------------------
53  struct timeval startCPUTime_;
54 
56  };
57 } // namespace edm
58 
59 #endif
ChildrenCPUTimer & operator=(const ChildrenCPUTimer &)=delete
double calculateDeltaTime() const
enum edm::ChildrenCPUTimer::State state_
struct timeval startCPUTime_
HLT enums.