CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Timing.h
Go to the documentation of this file.
1 #ifndef Services_TIMING_h
2 #define Services_TIMING_h
3 // -*- C++ -*-
4 //
5 // Package: Services
6 // Class : Timing
7 //
8 // Original Author: Jim Kowalkowski
9 //
10 
11 /*
12 Changes Log 1: 2009/01/14 10:29:00, Natalia Garcia Nebot
13  Modified the service to add some new measurements:
14  - Average time per event (cpu and wallclock)
15  - Fastest time per event (cpu and wallclock)
16  - Slowest time per event (cpu and wallclock)
17 */
18 
21 
22 namespace edm {
23  class ActivityRegistry;
24  class Event;
25  class EventSetup;
26  class ParameterSet;
28 
29  namespace service {
30  class Timing {
31  public:
33  ~Timing();
34 
35  static void fillDescriptions(edm::ConfigurationDescriptions & descriptions);
36 
37  private:
38  void postBeginJob();
39  void postEndJob();
40 
41  void preEventProcessing(EventID const&, Timestamp const&);
42  void postEventProcessing(Event const&, EventSetup const&);
43 
44  void preModule(ModuleDescription const&);
45  void postModule(ModuleDescription const&);
46 
48  double curr_job_time_; // seconds
49  double curr_job_cpu_; // seconds
50  double curr_event_time_; // seconds
51  double curr_event_cpu_; // seconds
52  double curr_module_time_; // seconds
53  double total_event_cpu_; // seconds
56 
57  //
58  // Min Max and average event times for summary
59  // at end of job
60  double max_event_time_; // seconds
61  double max_event_cpu_; // seconds
62  double min_event_time_; // seconds
63  double min_event_cpu_; // seconds
65  };
66  }
67 }
68 
69 #endif
double curr_job_time_
Definition: Timing.h:48
double max_event_time_
Definition: Timing.h:60
bool report_summary_
Definition: Timing.h:55
double curr_event_cpu_
Definition: Timing.h:51
double curr_job_cpu_
Definition: Timing.h:49
void preModule(ModuleDescription const &)
Definition: Timing.cc:220
EventID curr_event_
Definition: Timing.h:47
double curr_module_time_
Definition: Timing.h:52
Timing(ParameterSet const &, ActivityRegistry &)
Definition: Timing.cc:82
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition: Timing.cc:112
void postModule(ModuleDescription const &)
Definition: Timing.cc:224
double max_event_cpu_
Definition: Timing.h:61
double total_event_cpu_
Definition: Timing.h:53
int total_event_count_
Definition: Timing.h:64
double min_event_cpu_
Definition: Timing.h:63
void preEventProcessing(EventID const &, Timestamp const &)
Definition: Timing.cc:185
void postEventProcessing(Event const &, EventSetup const &)
Definition: Timing.cc:191
double min_event_time_
Definition: Timing.h:62
double curr_event_time_
Definition: Timing.h:50