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

void addToCPUTime (double iTime) override
 
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 > extra_job_cpu_
 
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 168 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().

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

Definition at line 263 of file Timing.cc.

263  {
264  }

Member Function Documentation

void edm::service::Timing::addToCPUTime ( 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 266 of file Timing.cc.

References extra_job_cpu_.

266  {
267  //For accounting purposes we effectively can say we started earlier
268  double expected = extra_job_cpu_.load();
269  while( not extra_job_cpu_.compare_exchange_strong(expected,expected+iTime) ) {}
270  }
std::atomic< double > extra_job_cpu_
Definition: Timing.cc:81
void edm::service::Timing::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 276 of file Timing.cc.

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

276  {
278  desc.addUntracked<bool>("summaryOnly", false)->setComment(
279  "If 'true' do not report timing for each event");
280  desc.addUntracked<bool>("useJobReport", true)->setComment(
281  "If 'true' write summary information to JobReport");
282  desc.addUntracked<double>("excessiveTimeThreshold", 0.)->setComment(
283  "Amount of time in seconds before reporting a module or source has taken excessive time. A value of 0.0 turns off this reporting.");
284  descriptions.add("Timing", desc);
285  descriptions.setComment(
286  "This service reports the time it takes to run each module in a job.");
287  }
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 272 of file Timing.cc.

References edm::service::getCPU().

272  {
273  return getCPU();
274  }
static double getCPU()
Definition: Timing.cc:125
void edm::service::Timing::postBeginJob ( )
private

Definition at line 289 of file Timing.cc.

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

Referenced by Timing().

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

Definition at line 470 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().

470  {
471  double t = popStack();
472  if(t > threshold_) {
473  LogError("ExcessiveTime")
474  << "ExcessiveTime: Module used " << t
475  << " seconds of time which exceeds the error threshold configured in the Timing Service of "
476  << threshold_ << " seconds.";
477  }
478  return t;
479  }
static double popStack()
Definition: Timing.cc:153
void edm::service::Timing::postEndJob ( )
private

Definition at line 304 of file Timing.cc.

References curr_job_cpu_, curr_job_time_, edm::service::d2str(), extra_job_cpu_, 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().

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

Definition at line 374 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().

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

Definition at line 445 of file Timing.cc.

References postCommon().

Referenced by Timing().

445  {
446  postCommon();
447  }
double postCommon() const
Definition: Timing.cc:470
void edm::service::Timing::postModuleEvent ( StreamContext const &  iStream,
ModuleCallingContext const &  iModule 
)
private

Definition at line 393 of file Timing.cc.

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

Referenced by Timing().

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

Definition at line 455 of file Timing.cc.

References postCommon().

Referenced by Timing().

455  {
456  postCommon();
457  }
double postCommon() const
Definition: Timing.cc:470
void edm::service::Timing::postModuleStream ( StreamContext const &  ,
ModuleCallingContext const &  mcc 
)
private

Definition at line 465 of file Timing.cc.

References postCommon().

Referenced by Timing().

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

Definition at line 435 of file Timing.cc.

References postCommon().

Referenced by Timing().

435  {
436  postCommon();
437  }
double postCommon() const
Definition: Timing.cc:470
void edm::service::Timing::postSourceEvent ( StreamID  sid)
private

Definition at line 411 of file Timing.cc.

References postCommon().

Referenced by Timing().

411  {
412  postCommon();
413  }
double postCommon() const
Definition: Timing.cc:470
void edm::service::Timing::postSourceLumi ( )
private

Definition at line 419 of file Timing.cc.

References postCommon().

Referenced by Timing().

419  {
420  postCommon();
421  }
double postCommon() const
Definition: Timing.cc:470
void edm::service::Timing::postSourceRun ( )
private

Definition at line 427 of file Timing.cc.

References postCommon().

Referenced by Timing().

427  {
428  postCommon();
429  }
double postCommon() const
Definition: Timing.cc:470
void edm::service::Timing::preEvent ( StreamContext const &  iStream)
private

Definition at line 369 of file Timing.cc.

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

Referenced by Timing().

369  {
370  auto index = iStream.streamID().value();
372  }
std::vector< double > curr_events_time_
Definition: Timing.cc:85
static double getTime()
Definition: Timing.cc:118
void edm::service::Timing::preModule ( ModuleDescription const &  md)
private

Definition at line 440 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

440  {
441  pushStack();
442  }
static void pushStack()
Definition: Timing.cc:163
void edm::service::Timing::preModuleGlobal ( GlobalContext const &  ,
ModuleCallingContext const &   
)
private

Definition at line 450 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

450  {
451  pushStack();
452  }
static void pushStack()
Definition: Timing.cc:163
void edm::service::Timing::preModuleStream ( StreamContext const &  ,
ModuleCallingContext const &   
)
private

Definition at line 460 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

460  {
461  pushStack();
462  }
static void pushStack()
Definition: Timing.cc:163
void edm::service::Timing::preOpenFile ( std::string const &  lfn,
bool  b 
)
private

Definition at line 431 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

431  {
432  pushStack();
433  }
static void pushStack()
Definition: Timing.cc:163
void edm::service::Timing::preSourceEvent ( StreamID  sid)
private

Definition at line 407 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

407  {
408  pushStack();
409  }
static void pushStack()
Definition: Timing.cc:163
void edm::service::Timing::preSourceLumi ( )
private

Definition at line 415 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

415  {
416  pushStack();
417  }
static void pushStack()
Definition: Timing.cc:163
void edm::service::Timing::preSourceRun ( )
private

Definition at line 423 of file Timing.cc.

References edm::service::pushStack().

Referenced by Timing().

423  {
424  pushStack();
425  }
static void pushStack()
Definition: Timing.cc:163

Member Data Documentation

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

Definition at line 85 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 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::extra_job_cpu_
private

Definition at line 81 of file Timing.cc.

Referenced by addToCPUTime(), and postEndJob().

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

Definition at line 84 of file Timing.cc.

Referenced by postEndJob(), and Timing().

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

Definition at line 83 of file Timing.cc.

Referenced by postEndJob(), and Timing().

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

Definition at line 92 of file Timing.cc.

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

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

Definition at line 93 of file Timing.cc.

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

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

Definition at line 96 of file Timing.cc.

Referenced by postEndJob(), and Timing().

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

Definition at line 97 of file Timing.cc.

Referenced by postEndJob(), and Timing().

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

Definition at line 87 of file Timing.cc.

Referenced by postEndJob().

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

Definition at line 94 of file Timing.cc.

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

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

Definition at line 86 of file Timing.cc.

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

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

Definition at line 88 of file Timing.cc.

Referenced by postCommon(), and Timing().

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

Definition at line 95 of file Timing.cc.

Referenced by postEndJob(), and postEvent().