CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
edm::service::Timing Class Reference
Inheritance diagram for edm::service::Timing:
edm::TimingServiceBase

Public Member Functions

virtual void addToCPUTime (StreamID id, double iTime) override
 
virtual double getTotalCPU () const override
 
 Timing (ParameterSet const &, ActivityRegistry &)
 
 ~Timing ()
 
- Public Member Functions inherited from edm::TimingServiceBase
 TimingServiceBase ()
 
virtual ~TimingServiceBase ()
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 

Private Member Functions

void postBeginJob ()
 
double postCommon () const
 
void postEndJob ()
 
void postEvent (StreamContext const &)
 
void postModule (ModuleDescription const &md)
 
void postModuleEvent (StreamContext const &, ModuleCallingContext const &)
 
void postModuleGlobal (GlobalContext const &, ModuleCallingContext const &)
 
void postModuleStream (StreamContext const &, ModuleCallingContext const &)
 
void postOpenFile (std::string const &, bool)
 
void postSourceEvent (StreamID)
 
void postSourceLumi ()
 
void postSourceRun ()
 
void preEvent (StreamContext const &)
 
void preModule (ModuleDescription const &md)
 
void preModuleGlobal (GlobalContext const &, ModuleCallingContext const &)
 
void preModuleStream (StreamContext const &, ModuleCallingContext const &)
 
void preOpenFile (std::string const &, bool)
 
void preSourceEvent (StreamID)
 
void preSourceLumi ()
 
void preSourceRun ()
 

Private Attributes

std::vector< double > curr_events_time_
 
double curr_job_cpu_
 
double curr_job_time_
 
std::atomic< double > last_run_cpu_
 
std::atomic< double > last_run_time_
 
std::vector< double > max_events_time_
 
std::vector< double > min_events_time_
 
unsigned int nStreams_
 
unsigned int nThreads_
 
bool report_summary_
 
std::vector< double > sum_events_time_
 
bool summary_only_
 
double threshold_
 
std::atomic< unsigned long > total_event_count_
 

Detailed Description

Definition at line 36 of file Timing.cc.

Constructor & Destructor Documentation

edm::service::Timing::Timing ( ParameterSet const &  iPS,
ActivityRegistry iRegistry 
)

Definition at line 167 of file Timing.cc.

References edm::signalslot::Signal< T >::connect(), curr_events_time_, edm::service::getCPU(), edm::service::getTime(), last_run_cpu_, last_run_time_, hpstanc_transforms::max, max_events_time_, edm::service::SystemBounds::maxNumberOfStreams(), edm::service::SystemBounds::maxNumberOfThreads(), min_events_time_, nStreams_, nThreads_, postBeginJob(), postEndJob(), postEvent(), edm::ActivityRegistry::postGlobalEndRunSignal_, postModule(), postModuleEvent(), postModuleGlobal(), postModuleStream(), postOpenFile(), postSourceEvent(), postSourceLumi(), postSourceRun(), edm::ActivityRegistry::preallocateSignal_, preEvent(), preModule(), preModuleGlobal(), preModuleStream(), preOpenFile(), preSourceEvent(), preSourceLumi(), preSourceRun(), sum_events_time_, summary_only_, threshold_, edm::ActivityRegistry::watchPostBeginJob(), edm::ActivityRegistry::watchPostEndJob(), edm::ActivityRegistry::watchPostEvent(), edm::ActivityRegistry::watchPostEventReadFromSource(), edm::ActivityRegistry::watchPostModuleBeginJob(), edm::ActivityRegistry::watchPostModuleConstruction(), edm::ActivityRegistry::watchPostModuleEndJob(), edm::ActivityRegistry::watchPostModuleEvent(), edm::ActivityRegistry::watchPostModuleGlobalBeginLumi(), edm::ActivityRegistry::watchPostModuleGlobalBeginRun(), edm::ActivityRegistry::watchPostModuleGlobalEndLumi(), edm::ActivityRegistry::watchPostModuleGlobalEndRun(), edm::ActivityRegistry::watchPostModuleStreamBeginLumi(), edm::ActivityRegistry::watchPostModuleStreamBeginRun(), edm::ActivityRegistry::watchPostModuleStreamEndLumi(), edm::ActivityRegistry::watchPostModuleStreamEndRun(), edm::ActivityRegistry::watchPostOpenFile(), edm::ActivityRegistry::watchPostSourceConstruction(), edm::ActivityRegistry::watchPostSourceEvent(), edm::ActivityRegistry::watchPostSourceLumi(), edm::ActivityRegistry::watchPostSourceRun(), edm::ActivityRegistry::watchPreEvent(), edm::ActivityRegistry::watchPreEventReadFromSource(), edm::ActivityRegistry::watchPreModuleBeginJob(), edm::ActivityRegistry::watchPreModuleConstruction(), edm::ActivityRegistry::watchPreModuleEndJob(), edm::ActivityRegistry::watchPreModuleEvent(), edm::ActivityRegistry::watchPreModuleGlobalBeginLumi(), edm::ActivityRegistry::watchPreModuleGlobalBeginRun(), edm::ActivityRegistry::watchPreModuleGlobalEndLumi(), edm::ActivityRegistry::watchPreModuleGlobalEndRun(), edm::ActivityRegistry::watchPreModuleStreamBeginLumi(), edm::ActivityRegistry::watchPreModuleStreamBeginRun(), edm::ActivityRegistry::watchPreModuleStreamEndLumi(), edm::ActivityRegistry::watchPreModuleStreamEndRun(), edm::ActivityRegistry::watchPreOpenFile(), edm::ActivityRegistry::watchPreSourceConstruction(), edm::ActivityRegistry::watchPreSourceEvent(), edm::ActivityRegistry::watchPreSourceLumi(), and edm::ActivityRegistry::watchPreSourceRun().

167  :
168  curr_job_time_(0.),
169  curr_job_cpu_(0.),
170  last_run_time_(0.0),
171  last_run_cpu_(0.0),
173  summary_only_(iPS.getUntrackedParameter<bool>("summaryOnly")),
174  report_summary_(iPS.getUntrackedParameter<bool>("useJobReport")),
175  threshold_(iPS.getUntrackedParameter<double>("excessiveTimeThreshold")),
178  total_event_count_(0) {
179  iRegistry.watchPostBeginJob(this, &Timing::postBeginJob);
180  iRegistry.watchPostEndJob(this, &Timing::postEndJob);
181 
182  iRegistry.watchPreEvent(this, &Timing::preEvent);
183  iRegistry.watchPostEvent(this, &Timing::postEvent);
184 
185  bool checkThreshold = true;
186  if (threshold_ <= 0.0) {
187  //we need to ignore the threshold check
189  checkThreshold = false;
190  }
191 
192  if( (not summary_only_) || (checkThreshold) ) {
193  iRegistry.watchPreModuleEvent(this, &Timing::preModuleStream);
194  iRegistry.watchPostModuleEvent(this, &Timing::postModuleEvent);
195  }
196  if(checkThreshold) {
197  iRegistry.watchPreSourceEvent(this, &Timing::preSourceEvent);
198  iRegistry.watchPostSourceEvent(this, &Timing::postSourceEvent);
199 
200  iRegistry.watchPreSourceLumi(this, &Timing::preSourceLumi);
201  iRegistry.watchPostSourceLumi(this, &Timing::postSourceLumi);
202 
203  iRegistry.watchPreSourceRun(this, &Timing::preSourceRun);
204  iRegistry.watchPostSourceRun(this, &Timing::postSourceRun);
205 
206  iRegistry.watchPreOpenFile(this, &Timing::preOpenFile);
207  iRegistry.watchPostOpenFile(this, &Timing::postOpenFile);
208 
209  iRegistry.watchPreEventReadFromSource(this, &Timing::preModuleStream);
210  iRegistry.watchPostEventReadFromSource(this, &Timing::postModuleStream);
211 
212  iRegistry.watchPreModuleConstruction(this, &Timing::preModule);
213  iRegistry.watchPostModuleConstruction(this, &Timing::postModule);
214 
215  iRegistry.watchPreModuleBeginJob(this, &Timing::preModule);
216  iRegistry.watchPostModuleBeginJob(this, &Timing::postModule);
217 
218  iRegistry.watchPreModuleEndJob(this, &Timing::preModule);
219  iRegistry.watchPostModuleEndJob(this, &Timing::postModule);
220 
221  iRegistry.watchPreModuleStreamBeginRun(this, &Timing::preModuleStream);
222  iRegistry.watchPostModuleStreamBeginRun(this, &Timing::postModuleStream);
223  iRegistry.watchPreModuleStreamEndRun(this, &Timing::preModuleStream);
224  iRegistry.watchPostModuleStreamEndRun(this, &Timing::postModuleStream);
225 
226  iRegistry.watchPreModuleStreamBeginLumi(this, &Timing::preModuleStream);
227  iRegistry.watchPostModuleStreamBeginLumi(this, &Timing::postModuleStream);
228  iRegistry.watchPreModuleStreamEndLumi(this, &Timing::preModuleStream);
229  iRegistry.watchPostModuleStreamEndLumi(this, &Timing::postModuleStream);
230 
231  iRegistry.watchPreModuleGlobalBeginRun(this, &Timing::preModuleGlobal);
232  iRegistry.watchPostModuleGlobalBeginRun(this, &Timing::postModuleGlobal);
233  iRegistry.watchPreModuleGlobalEndRun(this, &Timing::preModuleGlobal);
234  iRegistry.watchPostModuleGlobalEndRun(this, &Timing::postModuleGlobal);
235 
236  iRegistry.watchPreModuleGlobalBeginLumi(this, &Timing::preModuleGlobal);
237  iRegistry.watchPostModuleGlobalBeginLumi(this, &Timing::postModuleGlobal);
238  iRegistry.watchPreModuleGlobalEndLumi(this, &Timing::preModuleGlobal);
239  iRegistry.watchPostModuleGlobalEndLumi(this, &Timing::postModuleGlobal);
240 
241  iRegistry.watchPreSourceConstruction(this, &Timing::preModule);
242  iRegistry.watchPostSourceConstruction(this, &Timing::postModule);
243  }
244 
245  iRegistry.preallocateSignal_.connect([this](service::SystemBounds const& iBounds){
246  nStreams_ = iBounds.maxNumberOfStreams();
247  nThreads_ = iBounds.maxNumberOfThreads();
248  curr_events_time_.resize(nStreams_,0.);
249  sum_events_time_.resize(nStreams_,0.);
250  max_events_time_.resize(nStreams_,0.);
251  min_events_time_.resize(nStreams_,1.E6);
252 
253  });
254 
255  iRegistry.postGlobalEndRunSignal_.connect([this](edm::GlobalContext const&) {
257  last_run_cpu_ = getCPU();
258  });
259  }
std::vector< double > sum_events_time_
Definition: Timing.cc:93
double curr_job_time_
Definition: Timing.cc:79
std::atomic< double > last_run_cpu_
Definition: Timing.cc:83
std::vector< double > max_events_time_
Definition: Timing.cc:91
std::vector< double > curr_events_time_
Definition: Timing.cc:84
void preModule(ModuleDescription const &md)
Definition: Timing.cc:435
static double getCPU()
Definition: Timing.cc:124
void postEvent(StreamContext const &)
Definition: Timing.cc:369
void preModuleStream(StreamContext const &, ModuleCallingContext const &)
Definition: Timing.cc:455
double curr_job_cpu_
Definition: Timing.cc:80
unsigned int nThreads_
Definition: Timing.cc:96
void preOpenFile(std::string const &, bool)
Definition: Timing.cc:426
unsigned int nStreams_
Definition: Timing.cc:95
void preModuleGlobal(GlobalContext const &, ModuleCallingContext const &)
Definition: Timing.cc:445
void postModule(ModuleDescription const &md)
Definition: Timing.cc:440
void postModuleStream(StreamContext const &, ModuleCallingContext const &)
Definition: Timing.cc:460
void postModuleEvent(StreamContext const &, ModuleCallingContext const &)
Definition: Timing.cc:388
std::atomic< double > last_run_time_
Definition: Timing.cc:82
void preSourceLumi()
Definition: Timing.cc:410
void postSourceRun()
Definition: Timing.cc:422
std::atomic< unsigned long > total_event_count_
Definition: Timing.cc:94
void postSourceLumi()
Definition: Timing.cc:414
void postModuleGlobal(GlobalContext const &, ModuleCallingContext const &)
Definition: Timing.cc:450
void postOpenFile(std::string const &, bool)
Definition: Timing.cc:430
static double getTime()
Definition: Timing.cc:117
void postSourceEvent(StreamID)
Definition: Timing.cc:406
void preSourceEvent(StreamID)
Definition: Timing.cc:402
void preEvent(StreamContext const &)
Definition: Timing.cc:364
std::vector< double > min_events_time_
Definition: Timing.cc:92
edm::service::Timing::~Timing ( )

Definition at line 261 of file Timing.cc.

261  {
262  }

Member Function Documentation

void edm::service::Timing::addToCPUTime ( StreamID  id,
double  iTime 
)
overridevirtual

Extra CPU time used by a job but not seen by cmsRun The value should be in seconds. This function is safe to call from multiple threads

Implements edm::TimingServiceBase.

Definition at line 264 of file Timing.cc.

References curr_job_cpu_.

264  {
265  //For accounting purposes we effectively can say we started earlier
266  curr_job_cpu_ -= iTime;
267  }
double curr_job_cpu_
Definition: Timing.cc:80
void edm::service::Timing::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 273 of file Timing.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::addUntracked(), edm::ConfigurationDescriptions::setComment(), and edm::ParameterDescriptionNode::setComment().

273  {
275  desc.addUntracked<bool>("summaryOnly", false)->setComment(
276  "If 'true' do not report timing for each event");
277  desc.addUntracked<bool>("useJobReport", true)->setComment(
278  "If 'true' write summary information to JobReport");
279  desc.addUntracked<double>("excessiveTimeThreshold", 0.)->setComment(
280  "Amount of time in seconds before reporting a module or source has taken excessive time. A value of 0.0 turns off this reporting.");
281  descriptions.add("Timing", desc);
282  descriptions.setComment(
283  "This service reports the time it takes to run each module in a job.");
284  }
void setComment(std::string const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
double edm::service::Timing::getTotalCPU ( ) const
overridevirtual

CPU time used by this process and all its children. The value returned should be in seconds.

Implements edm::TimingServiceBase.

Definition at line 269 of file Timing.cc.

References edm::service::getCPU().

269  {
270  return getCPU();
271  }
static double getCPU()
Definition: Timing.cc:124
void edm::service::Timing::postBeginJob ( )
private

Definition at line 286 of file Timing.cc.

References curr_job_cpu_, curr_job_time_, edm::service::getCPU(), edm::service::getTime(), and summary_only_.

Referenced by Timing().

286  {
288  curr_job_cpu_ = getCPU();
289 
290  if(not summary_only_) {
291  LogImportant("TimeReport")
292  << "TimeReport> Report activated" << "\n"
293  << "TimeReport> Report columns headings for events: "
294  << "eventnum runnum timetaken\n"
295  << "TimeReport> Report columns headings for modules: "
296  << "eventnum runnum modulelabel modulename timetakeni\n"
297  << "TimeReport> JobTime=" << curr_job_time_ << " JobCPU=" << curr_job_cpu_ << "\n";
298  }
299  }
double curr_job_time_
Definition: Timing.cc:79
static double getCPU()
Definition: Timing.cc:124
double curr_job_cpu_
Definition: Timing.cc:80
static double getTime()
Definition: Timing.cc:117
double edm::service::Timing::postCommon ( ) const
private

Definition at line 465 of file Timing.cc.

References edm::service::popStack(), lumiQTWidget::t, threshold_, and trackingPlots::Timing.

Referenced by postModule(), postModuleEvent(), postModuleGlobal(), postModuleStream(), postOpenFile(), postSourceEvent(), postSourceLumi(), and postSourceRun().

465  {
466  double t = popStack();
467  if(t > threshold_) {
468  LogError("ExcessiveTime")
469  << "ExcessiveTime: Module used " << t
470  << " seconds of time which exceeds the error threshold configured in the Timing Service of "
471  << threshold_ << " seconds.";
472  }
473  return t;
474  }
static double popStack()
Definition: Timing.cc:152
void edm::service::Timing::postEndJob ( )
private

Definition at line 301 of file Timing.cc.

References curr_job_cpu_, curr_job_time_, edm::service::d2str(), edm::service::getCPU(), edm::service::getTime(), last_run_cpu_, last_run_time_, max_events_time_, min_events_time_, nStreams_, nThreads_, report_summary_, sum_events_time_, lumiQTWidget::t, total_event_count_, and edm::service::ui2str().

Referenced by Timing().

301  {
302  double total_job_time = getTime() - curr_job_time_;
303 
304  double total_job_cpu = getCPU() - curr_job_cpu_;
305 
306  double min_event_time = *(std::min_element(min_events_time_.begin(),
307  min_events_time_.end()));
308  double max_event_time = *(std::max_element(max_events_time_.begin(),
309  max_events_time_.end()));
310 
311  auto total_loop_time = last_run_time_ - curr_job_time_;
312  auto total_loop_cpu = last_run_cpu_ - curr_job_cpu_;
313 
314  if(last_run_time_ == 0.0) {
315  total_loop_time = 0.0;
316  total_loop_cpu = 0.0;
317  }
318 
319  double sum_all_events_time = 0;
320  for(auto t : sum_events_time_) { sum_all_events_time += t; }
321 
322  double average_event_time = 0.0;
323  if(total_event_count_ != 0) {
324  average_event_time = sum_all_events_time / total_event_count_;
325  }
326 
327  double event_throughput = 0.0;
328  if(total_loop_time != 0.0) {
329  event_throughput = total_event_count_ / total_loop_time;
330  }
331 
332  LogImportant("TimeReport")
333  << "TimeReport> Time report complete in "
334  << total_job_time << " seconds"
335  << "\n"
336  << " Time Summary: \n"
337  << " - Min event: " << min_event_time << "\n"
338  << " - Max event: " << max_event_time << "\n"
339  << " - Avg event: " << average_event_time << "\n"
340  << " - Total loop: " <<total_loop_time <<"\n"
341  << " - Total job: " << total_job_time << "\n"
342  << " Event Throughput: "<< event_throughput <<" ev/s\n"
343  << " CPU Summary: \n"
344  << " - Total loop: " << total_loop_cpu << "\n"
345  << " - Total job: " << total_job_cpu << "\n";
346 
347  if(report_summary_) {
348  Service<JobReport> reportSvc;
349  std::map<std::string, std::string> reportData;
350 
351  reportData.insert(std::make_pair("MinEventTime", d2str(min_event_time)));
352  reportData.insert(std::make_pair("MaxEventTime", d2str(max_event_time)));
353  reportData.insert(std::make_pair("AvgEventTime", d2str(average_event_time)));
354  reportData.insert(std::make_pair("EventThroughput", d2str(event_throughput)));
355  reportData.insert(std::make_pair("TotalJobTime", d2str(total_job_time)));
356  reportData.insert(std::make_pair("TotalJobCPU", d2str(total_job_cpu)));
357  reportData.insert(std::make_pair("TotalLoopCPU", d2str(total_loop_cpu)));
358  reportData.insert(std::make_pair("NumberOfStreams",ui2str(nStreams_)));
359  reportData.insert(std::make_pair("NumberOfThreads",ui2str(nThreads_)));
360  reportSvc->reportPerformanceSummary("Timing", reportData);
361  }
362  }
std::vector< double > sum_events_time_
Definition: Timing.cc:93
double curr_job_time_
Definition: Timing.cc:79
std::atomic< double > last_run_cpu_
Definition: Timing.cc:83
std::vector< double > max_events_time_
Definition: Timing.cc:91
static double getCPU()
Definition: Timing.cc:124
double curr_job_cpu_
Definition: Timing.cc:80
unsigned int nThreads_
Definition: Timing.cc:96
unsigned int nStreams_
Definition: Timing.cc:95
std::atomic< double > last_run_time_
Definition: Timing.cc:82
static std::string ui2str(unsigned int i)
Definition: Timing.cc:110
std::atomic< unsigned long > total_event_count_
Definition: Timing.cc:94
static std::string d2str(double d)
static double getTime()
Definition: Timing.cc:117
std::vector< double > min_events_time_
Definition: Timing.cc:92
void edm::service::Timing::postEvent ( StreamContext const &  iStream)
private

Definition at line 369 of file Timing.cc.

References curr_events_time_, edm::StreamContext::eventID(), edm::service::getTime(), diffTreeTool::index, max_events_time_, min_events_time_, edm::StreamContext::streamID(), sum_events_time_, summary_only_, total_event_count_, and edm::StreamID::value().

Referenced by Timing().

369  {
370  auto index = iStream.streamID().value();
371 
372  double curr_event_time = getTime() - curr_events_time_[index];
373  sum_events_time_[index] +=curr_event_time;
374 
375  if(not summary_only_) {
376  auto const & eventID = iStream.eventID();
377  LogPrint("TimeEvent")
378  << "TimeEvent> "
379  << eventID.event() << " "
380  << eventID.run() << " "
381  << curr_event_time ;
382  }
383  if(curr_event_time > max_events_time_[index]) max_events_time_[index] = curr_event_time;
384  if(curr_event_time < min_events_time_[index]) min_events_time_[index] = curr_event_time;
386  }
std::vector< double > sum_events_time_
Definition: Timing.cc:93
std::vector< double > max_events_time_
Definition: Timing.cc:91
std::vector< double > curr_events_time_
Definition: Timing.cc:84
std::atomic< unsigned long > total_event_count_
Definition: Timing.cc:94
static double getTime()
Definition: Timing.cc:117
std::vector< double > min_events_time_
Definition: Timing.cc:92
void edm::service::Timing::postModule ( ModuleDescription const &  md)
private

Definition at line 440 of file Timing.cc.

References postCommon().

Referenced by Timing().

440  {
441  postCommon();
442  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postModuleEvent ( StreamContext const &  iStream,
ModuleCallingContext const &  iModule 
)
private

Definition at line 388 of file Timing.cc.

References edm::StreamContext::eventID(), edm::ModuleCallingContext::moduleDescription(), postCommon(), summary_only_, and lumiQTWidget::t.

Referenced by Timing().

388  {
389  auto const & eventID = iStream.eventID();
390  auto const & desc = *(iModule.moduleDescription());
391  double t = postCommon();
392  if ( not summary_only_) {
393  LogPrint("TimeModule") << "TimeModule> "
394  << eventID.event() << " "
395  << eventID.run() << " "
396  << desc.moduleLabel() << " "
397  << desc.moduleName() << " "
398  << t;
399  }
400  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postModuleGlobal ( GlobalContext const &  ,
ModuleCallingContext const &  mcc 
)
private

Definition at line 450 of file Timing.cc.

References postCommon().

Referenced by Timing().

450  {
451  postCommon();
452  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postModuleStream ( StreamContext const &  ,
ModuleCallingContext const &  mcc 
)
private

Definition at line 460 of file Timing.cc.

References postCommon().

Referenced by Timing().

460  {
461  postCommon();
462  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postOpenFile ( std::string const &  lfn,
bool  b 
)
private

Definition at line 430 of file Timing.cc.

References postCommon().

Referenced by Timing().

430  {
431  postCommon();
432  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postSourceEvent ( StreamID  sid)
private

Definition at line 406 of file Timing.cc.

References postCommon().

Referenced by Timing().

406  {
407  postCommon();
408  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postSourceLumi ( )
private

Definition at line 414 of file Timing.cc.

References postCommon().

Referenced by Timing().

414  {
415  postCommon();
416  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::postSourceRun ( )
private

Definition at line 422 of file Timing.cc.

References postCommon().

Referenced by Timing().

422  {
423  postCommon();
424  }
double postCommon() const
Definition: Timing.cc:465
void edm::service::Timing::preEvent ( StreamContext const &  iStream)
private

Definition at line 364 of file Timing.cc.

References curr_events_time_, edm::service::getTime(), diffTreeTool::index, edm::StreamContext::streamID(), and edm::StreamID::value().

Referenced by Timing().

364  {
365  auto index = iStream.streamID().value();
367  }
std::vector< double > curr_events_time_
Definition: Timing.cc:84
static double getTime()
Definition: Timing.cc:117
void edm::service::Timing::preModule ( ModuleDescription const &  md)
private

Definition at line 435 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

435  {
436  pushStack();
437  }
static void pushStack()
Definition: Timing.cc:162
void edm::service::Timing::preModuleGlobal ( GlobalContext const &  ,
ModuleCallingContext const &   
)
private

Definition at line 445 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

445  {
446  pushStack();
447  }
static void pushStack()
Definition: Timing.cc:162
void edm::service::Timing::preModuleStream ( StreamContext const &  ,
ModuleCallingContext const &   
)
private

Definition at line 455 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

455  {
456  pushStack();
457  }
static void pushStack()
Definition: Timing.cc:162
void edm::service::Timing::preOpenFile ( std::string const &  lfn,
bool  b 
)
private

Definition at line 426 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

426  {
427  pushStack();
428  }
static void pushStack()
Definition: Timing.cc:162
void edm::service::Timing::preSourceEvent ( StreamID  sid)
private

Definition at line 402 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

402  {
403  pushStack();
404  }
static void pushStack()
Definition: Timing.cc:162
void edm::service::Timing::preSourceLumi ( )
private

Definition at line 410 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

410  {
411  pushStack();
412  }
static void pushStack()
Definition: Timing.cc:162
void edm::service::Timing::preSourceRun ( )
private

Definition at line 418 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

418  {
419  pushStack();
420  }
static void pushStack()
Definition: Timing.cc:162

Member Data Documentation

std::vector<double> edm::service::Timing::curr_events_time_
private

Definition at line 84 of file Timing.cc.

Referenced by postEvent(), preEvent(), and Timing().

double edm::service::Timing::curr_job_cpu_
private

Definition at line 80 of file Timing.cc.

Referenced by addToCPUTime(), postBeginJob(), and postEndJob().

double edm::service::Timing::curr_job_time_
private

Definition at line 79 of file Timing.cc.

Referenced by postBeginJob(), and postEndJob().

std::atomic<double> edm::service::Timing::last_run_cpu_
private

Definition at line 83 of file Timing.cc.

Referenced by postEndJob(), and Timing().

std::atomic<double> edm::service::Timing::last_run_time_
private

Definition at line 82 of file Timing.cc.

Referenced by postEndJob(), and Timing().

std::vector<double> edm::service::Timing::max_events_time_
private

Definition at line 91 of file Timing.cc.

Referenced by postEndJob(), postEvent(), and Timing().

std::vector<double> edm::service::Timing::min_events_time_
private

Definition at line 92 of file Timing.cc.

Referenced by postEndJob(), postEvent(), and Timing().

unsigned int edm::service::Timing::nStreams_
private

Definition at line 95 of file Timing.cc.

Referenced by postEndJob(), and Timing().

unsigned int edm::service::Timing::nThreads_
private

Definition at line 96 of file Timing.cc.

Referenced by postEndJob(), and Timing().

bool edm::service::Timing::report_summary_
private

Definition at line 86 of file Timing.cc.

Referenced by postEndJob().

std::vector<double> edm::service::Timing::sum_events_time_
private

Definition at line 93 of file Timing.cc.

Referenced by postEndJob(), postEvent(), and Timing().

bool edm::service::Timing::summary_only_
private

Definition at line 85 of file Timing.cc.

Referenced by postBeginJob(), postEvent(), postModuleEvent(), and Timing().

double edm::service::Timing::threshold_
private

Definition at line 87 of file Timing.cc.

Referenced by postCommon(), and Timing().

std::atomic<unsigned long> edm::service::Timing::total_event_count_
private

Definition at line 94 of file Timing.cc.

Referenced by postEndJob(), and postEvent().