CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Tracer.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: Services
4 // Class : Tracer
5 //
6 // Implementation:
7 // <Notes on implementation>
8 //
9 // Original Author: Chris Jones
10 // Created: Thu Sep 8 14:17:58 EDT 2005
11 //
12 
19 
25 
33 
34 #include <iostream>
35 
36 using namespace edm::service;
37 
38 namespace {
39 
40  class TimeStamper {
41  public:
42  TimeStamper(bool enable) :
43  enabled_(enable)
44  { }
45 
46  friend
47  std::ostream & operator<<(std::ostream & out, TimeStamper const & timestamp) {
48  if (timestamp.enabled_)
49  out << std::setprecision(2) << edm::TimeOfDay() << " ";
50  return out;
51  }
52 
53  private:
54  bool enabled_;
55  };
56 
57 }
58 
60  indention_(iPS.getUntrackedParameter<std::string>("indention")),
61  dumpContextForLabels_(),
62  dumpNonModuleContext_(iPS.getUntrackedParameter<bool>("dumpNonModuleContext")),
63  printTimestamps_(iPS.getUntrackedParameter<bool>("printTimestamps"))
64 {
65  for (std::string & label: iPS.getUntrackedParameter<std::vector<std::string>>("dumpContextForLabels"))
66  dumpContextForLabels_.insert(std::move(label));
67 
68  iRegistry.watchPreallocate(this, &Tracer::preallocate);
69 
70  iRegistry.watchPostBeginJob(this, &Tracer::postBeginJob);
71  iRegistry.watchPostEndJob(this, &Tracer::postEndJob);
72 
75 
76  iRegistry.watchPreSourceLumi(this, &Tracer::preSourceLumi);
78 
79  iRegistry.watchPreSourceRun(this, &Tracer::preSourceRun);
80  iRegistry.watchPostSourceRun(this, &Tracer::postSourceRun);
81 
82  iRegistry.watchPreOpenFile(this, &Tracer::preOpenFile);
83  iRegistry.watchPostOpenFile(this, &Tracer::postOpenFile);
84 
85  iRegistry.watchPreCloseFile(this, &Tracer::preCloseFile);
86  iRegistry.watchPostCloseFile(this, &Tracer::postCloseFile);
87 
90 
93 
96 
99 
102 
105 
108 
111 
114 
117 
118  iRegistry.watchPreEvent(this, &Tracer::preEvent);
119  iRegistry.watchPostEvent(this, &Tracer::postEvent);
120 
121  iRegistry.watchPrePathEvent(this, &Tracer::prePathEvent);
122  iRegistry.watchPostPathEvent(this, &Tracer::postPathEvent);
123 
126 
129 
132 
137 
142 
147 
152 
157 
160 }
161 
162 void
165  desc.addUntracked<std::string>("indention", "++")->setComment("Prefix characters for output. The characters are repeated to form the indentation.");
166  desc.addUntracked<std::vector<std::string>>("dumpContextForLabels", std::vector<std::string>{})->setComment("Prints context information to cout for the module transitions associated with these modules' labels");
167  desc.addUntracked<bool>("dumpNonModuleContext", false)->setComment("Prints context information to cout for the transitions not associated with any module label");
168  desc.addUntracked<bool>("printTimestamps", false)->setComment("Prints a time stamp for every transition");
169  descriptions.add("Tracer", desc);
170  descriptions.setComment("This service prints each phase the framework is processing, e.g. constructing a module,running a module, etc.");
171 }
172 
173 void
175  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << " preallocate: " << bounds.maxNumberOfConcurrentRuns() << " concurrent runs, "
176  << bounds.maxNumberOfConcurrentLuminosityBlocks() << " concurrent luminosity sections, "
177  << bounds.maxNumberOfStreams() << " streams";
178 }
179 
180 void
182  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << " finished: begin job";
183 }
184 
185 void
187  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << " finished: end job";
188 }
189 
190 void
192  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << indention_ << " starting: source event";
193 }
194 
195 void
197  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << indention_ << " finished: source event";
198 }
199 
200 void
202  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << indention_ << " starting: source lumi";
203 }
204 
205 void
207  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << indention_ << " finished: source lumi";
208 }
209 
210 void
212  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << indention_ << " starting: source run";
213 }
214 
215 void
217  LogAbsolute("Tracer") << TimeStamper(printTimestamps_) << indention_ << indention_ << " finished: source run";
218 }
219 
220 void
221 Tracer::preOpenFile(std::string const& lfn, bool b) {
222  LogAbsolute out("Tracer");
223  out << TimeStamper(printTimestamps_);
224  out << indention_ << indention_ << " starting: open input file: lfn = " << lfn;
225  if(dumpNonModuleContext_) out << " usedFallBack = " << b;
226 }
227 
228 void
229 Tracer::postOpenFile (std::string const& lfn, bool b) {
230  LogAbsolute out("Tracer");
231  out << TimeStamper(printTimestamps_);
232  out << indention_ << indention_ << " finished: open input file: lfn = " << lfn;
233  if(dumpNonModuleContext_) out << " usedFallBack = " << b;
234 }
235 
236 void
237 Tracer::preCloseFile(std::string const & lfn, bool b) {
238  LogAbsolute out("Tracer");
239  out << TimeStamper(printTimestamps_);
240  out << indention_ << indention_ << " starting: close input file: lfn = " << lfn;
241  if(dumpNonModuleContext_) out << " usedFallBack = " << b;
242 }
243 void
244 Tracer::postCloseFile (std::string const& lfn, bool b) {
245  LogAbsolute out("Tracer");
246  out << TimeStamper(printTimestamps_);
247  out << indention_ << indention_ << " finished: close input file: lfn = " << lfn;
248  if(dumpNonModuleContext_) out << " usedFallBack = " << b;
249 }
250 
251 void
253  ModuleDescription const& desc = *mcc.moduleDescription();
254  LogAbsolute out("Tracer");
255  out << TimeStamper(printTimestamps_);
256  out << indention_ << indention_ << " starting: begin stream for module: stream = " << sc.streamID() << " label = '" << desc.moduleLabel() << "' id = " << desc.id();
257  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
258  out << "\n" << sc;
259  out << mcc;
260  }
261 }
262 
263 void
265  ModuleDescription const& desc = *mcc.moduleDescription();
266  LogAbsolute out("Tracer");
267  out << TimeStamper(printTimestamps_);
268  out << indention_ << indention_ << " finished: begin stream for module: stream = " << sc.streamID() << " label = '" << desc.moduleLabel() << "' id = " << desc.id();
269  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
270  out << "\n" << sc;
271  out << mcc;
272  }
273 }
274 
275 void
277  ModuleDescription const& desc = *mcc.moduleDescription();
278  LogAbsolute out("Tracer");
279  out << TimeStamper(printTimestamps_);
280  out << indention_ << indention_ << " starting: end stream for module: stream = " << sc.streamID() << " label = '" << desc.moduleLabel() << "' id = " << desc.id();
281  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
282  out << "\n" << sc;
283  out << mcc;
284  }
285 }
286 
287 void
289  ModuleDescription const& desc = *mcc.moduleDescription();
290  LogAbsolute out("Tracer");
291  out << TimeStamper(printTimestamps_);
292  out << indention_ << indention_ << " finished: end stream for module: stream = " << sc.streamID() << " label = '" << desc.moduleLabel() << "' id = " << desc.id();
293  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
294  out << "\n" << sc;
295  out << mcc;
296  }
297 }
298 
299 void
301  LogAbsolute out("Tracer");
302  out << TimeStamper(printTimestamps_);
303  out << indention_ << indention_ << " starting: global begin run " << gc.luminosityBlockID().run()
304  << " : time = " << gc.timestamp().value();
306  out << "\n" << gc;
307  }
308 }
309 
310 void
312  LogAbsolute out("Tracer");
313  out << TimeStamper(printTimestamps_);
314  out << indention_ << indention_ << " finished: global begin run " << gc.luminosityBlockID().run()
315  << " : time = " << gc.timestamp().value();
317  out << "\n" << gc;
318  }
319 }
320 
321 void
323  LogAbsolute out("Tracer");
324  out << TimeStamper(printTimestamps_);
325  out << indention_ << indention_ << " starting: global end run " << gc.luminosityBlockID().run()
326  << " : time = " << gc.timestamp().value();
328  out << "\n" << gc;
329  }
330 }
331 
332 void
334  LogAbsolute out("Tracer");
335  out << TimeStamper(printTimestamps_);
336  out << indention_ << indention_ << " finished: global end run " << gc.luminosityBlockID().run()
337  << " : time = " << gc.timestamp().value();
339  out << "\n" << gc;
340  }
341 }
342 
343 void
345  LogAbsolute out("Tracer");
346  out << TimeStamper(printTimestamps_);
347  out << indention_ << indention_ << " starting: begin run: stream = " << sc.streamID() << " run = " << sc.eventID().run()
348  << " time = " << sc.timestamp().value();
350  out << "\n" << sc;
351  }
352 }
353 
354 void
356  LogAbsolute out("Tracer");
357  out << TimeStamper(printTimestamps_);
358  out << indention_ << indention_ << " finished: begin run: stream = " << sc.streamID() << " run = " << sc.eventID().run()
359  << " time = " << sc.timestamp().value();
361  out << "\n" << sc;
362  }
363 }
364 
365 void
367  LogAbsolute out("Tracer");
368  out << TimeStamper(printTimestamps_);
369  out << indention_ << indention_ << " starting: end run: stream = " << sc.streamID() << " run = " << sc.eventID().run()
370  << " time = " << sc.timestamp().value();
372  out << "\n" << sc;
373  }
374 }
375 
376 void
378  LogAbsolute out("Tracer");
379  out << TimeStamper(printTimestamps_);
380  out << indention_ << indention_ << " finished: end run: stream = " << sc.streamID() << " run = " << sc.eventID().run()
381  << " time = " << sc.timestamp().value();
383  out << "\n" << sc;
384  }
385 }
386 
387 void
389  LogAbsolute out("Tracer");
390  out << TimeStamper(printTimestamps_);
391  out << indention_ << indention_ << " starting: global begin lumi: run = " << gc.luminosityBlockID().run()
392  << " lumi = " << gc.luminosityBlockID().luminosityBlock() << " time = " << gc.timestamp().value();
394  out << "\n" << gc;
395  }
396 }
397 
398 void
400  LogAbsolute out("Tracer");
401  out << TimeStamper(printTimestamps_);
402  out << indention_ << indention_ << " finished: global begin lumi: run = " << gc.luminosityBlockID().run()
403  << " lumi = " << gc.luminosityBlockID().luminosityBlock() << " time = " << gc.timestamp().value();
405  out << "\n" << gc;
406  }
407 }
408 
409 void
411  LogAbsolute out("Tracer");
412  out << TimeStamper(printTimestamps_);
413  out << indention_ << indention_ << " starting: global end lumi: run = " << gc.luminosityBlockID().run()
414  << " lumi = " << gc.luminosityBlockID().luminosityBlock() << " time = " << gc.timestamp().value();
416  out << "\n" << gc;
417  }
418 }
419 
420 void
422  LogAbsolute out("Tracer");
423  out << TimeStamper(printTimestamps_);
424  out << indention_ << indention_ << " finished: global end lumi: run = " << gc.luminosityBlockID().run()
425  << " lumi = " << gc.luminosityBlockID().luminosityBlock() << " time = " << gc.timestamp().value();
427  out << "\n" << gc;
428  }
429 }
430 
431 void
433  LogAbsolute out("Tracer");
434  out << TimeStamper(printTimestamps_);
435  out << indention_ << indention_ << " starting: begin lumi: stream = " << sc.streamID() << " run = " << sc.eventID().run()
436  << " lumi = " << sc.eventID().luminosityBlock() << " time = " << sc.timestamp().value();
438  out << "\n" << sc;
439  }
440 }
441 
442 void
444  LogAbsolute out("Tracer");
445  out << TimeStamper(printTimestamps_);
446  out << indention_ << indention_ << " finished: begin lumi: stream = " << sc.streamID() << " run = " << sc.eventID().run()
447  << " lumi = " << sc.eventID().luminosityBlock() << " time = " << sc.timestamp().value();
449  out << "\n" << sc;
450  }
451 }
452 
453 void
455  LogAbsolute out("Tracer");
456  out << TimeStamper(printTimestamps_);
457  out << indention_ << indention_ << " starting: end lumi: stream = " << sc.streamID() << " run = " << sc.eventID().run()
458  << " lumi = " << sc.eventID().luminosityBlock() << " time = " << sc.timestamp().value();
460  out << "\n" << sc;
461  }
462 }
463 
464 void
466  LogAbsolute out("Tracer");
467  out << TimeStamper(printTimestamps_);
468  out << indention_ << indention_ << " finished: end lumi: stream = " << sc.streamID() << " run = " << sc.eventID().run()
469  << " lumi = " << sc.eventID().luminosityBlock() << " time = " << sc.timestamp().value();
471  out << "\n" << sc;
472  }
473 }
474 
475 void
477  LogAbsolute out("Tracer");
478  out << TimeStamper(printTimestamps_);
479  out << indention_ << indention_ << " starting: processing event : stream = " << sc.streamID() << " run = " << sc.eventID().run()
480  << " lumi = " << sc.eventID().luminosityBlock() << " event = " << sc.eventID().event() << " time = " << sc.timestamp().value();
482  out << "\n" << sc;
483  }
484 }
485 
486 void
488  LogAbsolute out("Tracer");
489  out << TimeStamper(printTimestamps_);
490  out << indention_ << indention_ << " finished: processing event : stream = " << sc.streamID() << " run = " << sc.eventID().run()
491  << " lumi = " << sc.eventID().luminosityBlock() << " event = " << sc.eventID().event() << " time = " << sc.timestamp().value();
493  out << "\n" << sc;
494  }
495 }
496 
497 void
499  LogAbsolute out("Tracer");
500  out << TimeStamper(printTimestamps_);
501  out << indention_ << indention_ << indention_ << " starting: processing path '" << pc.pathName() << "' : stream = " << sc.streamID();
503  out << "\n" << sc;
504  out << pc;
505  }
506 }
507 
508 void
510  LogAbsolute out("Tracer");
511  out << TimeStamper(printTimestamps_);
512  out << indention_ << indention_ << indention_ << " finished: processing path '" << pc.pathName() << "' : stream = " << sc.streamID();
514  out << "\n" << sc;
515  out << pc;
516  }
517 }
518 
519 void
521  LogAbsolute out("Tracer");
522  out << TimeStamper(printTimestamps_);
523  out << indention_ << indention_ << " starting: constructing module with label '" << desc.moduleLabel() << "' id = " << desc.id();
524  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
525  out << "\n" << desc;
526  }
527 }
528 
529 void
531  LogAbsolute out("Tracer");
532  out << TimeStamper(printTimestamps_);
533  out << indention_ << indention_ << " finished: constructing module with label '" << desc.moduleLabel() << "' id = " << desc.id();
534  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
535  out << "\n" << desc;
536  }
537 }
538 
539 void
541  LogAbsolute out("Tracer");
542  out << TimeStamper(printTimestamps_);
543  out << indention_ << indention_;
544  out << " starting: begin job for module with label '" << desc.moduleLabel() << "' id = " << desc.id();
545  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
546  out << "\n" << desc;
547  }
548 }
549 
550 void
552  LogAbsolute out("Tracer");
553  out << TimeStamper(printTimestamps_);
554  out << indention_ << indention_;
555  out << " finished: begin job for module with label '" << desc.moduleLabel() << "' id = " << desc.id();
556  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
557  out << "\n" << desc;
558  }
559 }
560 
561 void
563  LogAbsolute out("Tracer");
564  out << TimeStamper(printTimestamps_);
565  out << indention_ << indention_;
566  out << " starting: end job for module with label '" << desc.moduleLabel() << "' id = " << desc.id();
567  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
568  out << "\n" << desc;
569  }
570 }
571 
572 void
574  LogAbsolute out("Tracer");
575  out << TimeStamper(printTimestamps_);
576  out << indention_ << indention_;
577  out << " finished: end job for module with label '" << desc.moduleLabel() << "' id = " << desc.id();
578  if(dumpContextForLabels_.find(desc.moduleLabel()) != dumpContextForLabels_.end()) {
579  out << "\n" << desc;
580  }
581 }
582 
583 void
585  LogAbsolute out("Tracer");
586  out << TimeStamper(printTimestamps_);
587  unsigned int nIndents = mcc.depth() + 4;
588  for(unsigned int i = 0; i < nIndents; ++i) {
589  out << indention_;
590  }
591  out << " starting: processing event for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
593  out << "\n" << sc;
594  out << mcc;
595  }
596 }
597 
598 void
600  LogAbsolute out("Tracer");
601  out << TimeStamper(printTimestamps_);
602  unsigned int nIndents = mcc.depth() + 4;
603  for(unsigned int i = 0; i < nIndents; ++i) {
604  out << indention_;
605  }
606  out << " finished: processing event for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
608  out << "\n" << sc;
609  out << mcc;
610  }
611 }
612 
613 
614 void
616  LogAbsolute out("Tracer");
617  out << TimeStamper(printTimestamps_);
618  unsigned int nIndents = mcc.depth() + 4;
619  for(unsigned int i = 0; i < nIndents; ++i) {
620  out << indention_;
621  }
622  out << " starting: delayed processing event for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
624  out << "\n" << sc;
625  out << mcc;
626  }
627 }
628 
629 void
631  LogAbsolute out("Tracer");
632  out << TimeStamper(printTimestamps_);
633  unsigned int nIndents = mcc.depth() + 4;
634  for(unsigned int i = 0; i < nIndents; ++i) {
635  out << indention_;
636  }
637  out << " finished: delayed processing event for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
639  out << "\n" << sc;
640  out << mcc;
641  }
642 }
643 
644 
645 void
647  LogAbsolute out("Tracer");
648  out << TimeStamper(printTimestamps_);
649  unsigned int nIndents = mcc.depth() + 3;
650  for(unsigned int i = 0; i < nIndents; ++i) {
651  out << indention_;
652  }
653  out << " starting: begin run for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
655  out << "\n" << sc;
656  out << mcc;
657  }
658 }
659 
660 void
662  LogAbsolute out("Tracer");
663  out << TimeStamper(printTimestamps_);
664  unsigned int nIndents = mcc.depth() + 3;
665  for(unsigned int i = 0; i < nIndents; ++i) {
666  out << indention_;
667  }
668  out << " finished: begin run for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
670  out << "\n" << sc;
671  out << mcc;
672  }
673 }
674 
675 void
677  LogAbsolute out("Tracer");
678  out << TimeStamper(printTimestamps_);
679  unsigned int nIndents = mcc.depth() + 3;
680  for(unsigned int i = 0; i < nIndents; ++i) {
681  out << indention_;
682  }
683  out << " starting: end run for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
685  out << "\n" << sc;
686  out << mcc;
687  }
688 }
689 
690 void
692  LogAbsolute out("Tracer");
693  out << TimeStamper(printTimestamps_);
694  unsigned int nIndents = mcc.depth() + 3;
695  for(unsigned int i = 0; i < nIndents; ++i) {
696  out << indention_;
697  }
698  out << " finished: end run for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
700  out << "\n" << sc;
701  out << mcc;
702  }
703 }
704 
705 void
707  LogAbsolute out("Tracer");
708  out << TimeStamper(printTimestamps_);
709  unsigned int nIndents = mcc.depth() + 3;
710  for(unsigned int i = 0; i < nIndents; ++i) {
711  out << indention_;
712  }
713  out << " starting: begin lumi for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
715  out << "\n" << sc;
716  out << mcc;
717  }
718 }
719 
720 void
722  LogAbsolute out("Tracer");
723  out << TimeStamper(printTimestamps_);
724  unsigned int nIndents = mcc.depth() + 3;
725  for(unsigned int i = 0; i < nIndents; ++i) {
726  out << indention_;
727  }
728  out << " finished: begin lumi for module: stream = " << sc.streamID() << " label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
730  out << "\n" << sc;
731  out << mcc;
732  }
733 }
734 
735 void
737  LogAbsolute out("Tracer");
738  out << TimeStamper(printTimestamps_);
739  unsigned int nIndents = mcc.depth() + 3;
740  for(unsigned int i = 0; i < nIndents; ++i) {
741  out << indention_;
742  }
743  out << " starting: end lumi for module: stream = " << sc.streamID() << " label = '"<< mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
745  out << "\n" << sc;
746  out << mcc;
747  }
748 }
749 
750 void
752  LogAbsolute out("Tracer");
753  out << TimeStamper(printTimestamps_);
754  unsigned int nIndents = mcc.depth() + 3;
755  for(unsigned int i = 0; i < nIndents; ++i) {
756  out << indention_;
757  }
758  out << " finished: end lumi for module: stream = " << sc.streamID() << " label = '"<< mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
760  out << "\n" << sc;
761  out << mcc;
762  }
763 }
764 
765 void
767  LogAbsolute out("Tracer");
768  out << TimeStamper(printTimestamps_);
769  unsigned int nIndents = mcc.depth() + 3;
770  for(unsigned int i = 0; i < nIndents; ++i) {
771  out << indention_;
772  }
773  out << " starting: global begin run for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
775  out << "\n" << gc;
776  out << mcc;
777  }
778 }
779 
780 void
782  LogAbsolute out("Tracer");
783  out << TimeStamper(printTimestamps_);
784  unsigned int nIndents = mcc.depth() + 3;
785  for(unsigned int i = 0; i < nIndents; ++i) {
786  out << indention_;
787  }
788  out << " finished: global begin run for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
790  out << "\n" << gc;
791  out << mcc;
792  }
793 }
794 
795 void
797  LogAbsolute out("Tracer");
798  out << TimeStamper(printTimestamps_);
799  unsigned int nIndents = mcc.depth() + 3;
800  for(unsigned int i = 0; i < nIndents; ++i) {
801  out << indention_;
802  }
803  out << " starting: global end run for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
805  out << "\n" << gc;
806  out << mcc;
807  }
808 }
809 
810 void
812  LogAbsolute out("Tracer");
813  out << TimeStamper(printTimestamps_);
814  unsigned int nIndents = mcc.depth() + 3;
815  for(unsigned int i = 0; i < nIndents; ++i) {
816  out << indention_;
817  }
818  out << " finished: global end run for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
820  out << "\n" << gc;
821  out << mcc;
822  }
823 }
824 
825 void
827  LogAbsolute out("Tracer");
828  out << TimeStamper(printTimestamps_);
829  unsigned int nIndents = mcc.depth() + 3;
830  for(unsigned int i = 0; i < nIndents; ++i) {
831  out << indention_;
832  }
833  out << " starting: global begin lumi for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
835  out << "\n" << gc;
836  out << mcc;
837  }
838 }
839 
840 void
842  LogAbsolute out("Tracer");
843  out << TimeStamper(printTimestamps_);
844  unsigned int nIndents = mcc.depth() + 3;
845  for(unsigned int i = 0; i < nIndents; ++i) {
846  out << indention_;
847  }
848  out << " finished: global begin lumi for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
850  out << "\n" << gc;
851  out << mcc;
852  }
853 }
854 
855 void
857  LogAbsolute out("Tracer");
858  out << TimeStamper(printTimestamps_);
859  unsigned int nIndents = mcc.depth() + 3;
860  for(unsigned int i = 0; i < nIndents; ++i) {
861  out << indention_;
862  }
863  out << " starting: global end lumi for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
865  out << "\n" << gc;
866  out << mcc;
867  }
868 }
869 
870 void
872  LogAbsolute out("Tracer");
873  out << TimeStamper(printTimestamps_);
874  unsigned int nIndents = mcc.depth() + 3;
875  for(unsigned int i = 0; i < nIndents; ++i) {
876  out << indention_;
877  }
878  out << " finished: global end lumi for module: label = '" << mcc.moduleDescription()->moduleLabel() << "' id = " << mcc.moduleDescription()->id();
880  out << "\n" << gc;
881  out << mcc;
882  }
883 }
884 
885 void
887  LogAbsolute out("Tracer");
888  out << TimeStamper(printTimestamps_);
889  out << indention_;
890  out << " starting: constructing source: " << desc.moduleName();
892  out << "\n" << desc;
893  }
894 }
895 
896 void
898  LogAbsolute out("Tracer");
899  out << TimeStamper(printTimestamps_);
900  out << indention_;
901  out << " finished: constructing source: " << desc.moduleName();
903  out << "\n" << desc;
904  }
905 }
void preCloseFile(std::string const &lfn, bool primary)
Definition: Tracer.cc:237
RunNumber_t run() const
Definition: EventID.h:42
void watchPostModuleGlobalEndLumi(PostModuleGlobalEndLumi::slot_type const &iSlot)
void watchPostModuleConstruction(PostModuleConstruction::slot_type const &iSlot)
std::string const & pathName() const
Definition: PathContext.h:37
EventNumber_t event() const
Definition: EventID.h:44
void watchPreModuleGlobalBeginRun(PreModuleGlobalBeginRun::slot_type const &iSlot)
T getUntrackedParameter(std::string const &, T const &) const
void watchPreEvent(PreEvent::slot_type const &iSlot)
int i
Definition: DBlmapReader.cc:9
void postSourceRun()
Definition: Tracer.cc:216
void watchPrePathEvent(PrePathEvent::slot_type const &iSlot)
void postModuleGlobalBeginRun(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:781
void watchPreallocate(Preallocate::slot_type const &iSlot)
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
void postModuleGlobalBeginLumi(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:841
void postModuleStreamEndLumi(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:751
void watchPostEndJob(PostEndJob::slot_type const &iSlot)
void preModuleGlobalBeginLumi(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:826
void postModuleConstruction(ModuleDescription const &md)
Definition: Tracer.cc:530
void postModuleEndStream(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:288
void postModuleGlobalEndLumi(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:871
void watchPostModuleEndStream(PostModuleEndStream::slot_type const &iSlot)
void watchPreModuleEvent(PreModuleEvent::slot_type const &iSlot)
void watchPreModuleConstruction(PreModuleConstruction::slot_type const &iSlot)
void watchPreGlobalEndLumi(PreGlobalEndLumi::slot_type const &iSlot)
void watchPostEvent(PostEvent::slot_type const &iSlot)
void preallocate(service::SystemBounds const &)
Definition: Tracer.cc:174
LuminosityBlockID const & luminosityBlockID() const
Definition: GlobalContext.h:52
void postStreamBeginLumi(StreamContext const &)
Definition: Tracer.cc:443
void watchPreStreamEndRun(PreStreamEndRun::slot_type const &iSlot)
void watchPreSourceConstruction(PreSourceConstruction::slot_type const &iSlot)
void preModuleGlobalEndLumi(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:856
void watchPostSourceConstruction(PostSourceConstruction::slot_type const &iSlot)
void watchPostStreamEndLumi(PostStreamEndLumi::slot_type const &iSlot)
void watchPreGlobalBeginLumi(PreGlobalBeginLumi::slot_type const &iSlot)
std::string const & moduleName() const
void watchPostPathEvent(PostPathEvent::slot_type const &iSlot)
void watchPostModuleEvent(PostModuleEvent::slot_type const &iSlot)
void preModuleStreamBeginLumi(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:706
void watchPostModuleGlobalBeginLumi(PostModuleGlobalBeginLumi::slot_type const &iSlot)
void watchPostModuleStreamEndLumi(PostModuleStreamEndLumi::slot_type const &iSlot)
void preGlobalEndLumi(GlobalContext const &)
Definition: Tracer.cc:410
void preModuleEndJob(ModuleDescription const &md)
Definition: Tracer.cc:562
void watchPostGlobalBeginLumi(PostGlobalBeginLumi::slot_type const &iSlot)
void watchPostModuleStreamBeginRun(PostModuleStreamBeginRun::slot_type const &iSlot)
void watchPostSourceEvent(PostSourceEvent::slot_type const &iSlot)
void preModuleConstruction(ModuleDescription const &md)
Definition: Tracer.cc:520
void watchPreModuleBeginStream(PreModuleBeginStream::slot_type const &iSlot)
void postStreamEndRun(StreamContext const &)
Definition: Tracer.cc:377
void postGlobalEndLumi(GlobalContext const &)
Definition: Tracer.cc:421
LuminosityBlockNumber_t luminosityBlock() const
Definition: EventID.h:43
void postModuleBeginJob(ModuleDescription const &md)
Definition: Tracer.cc:551
void watchPreStreamEndLumi(PreStreamEndLumi::slot_type const &iSlot)
void postModuleStreamEndRun(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:691
std::string const & moduleLabel() const
void watchPreModuleGlobalEndRun(PreModuleGlobalEndRun::slot_type const &iSlot)
void postCloseFile(std::string const &, bool)
Definition: Tracer.cc:244
Timestamp const & timestamp() const
Definition: GlobalContext.h:55
void preStreamEndLumi(StreamContext const &)
Definition: Tracer.cc:454
void preOpenFile(std::string const &, bool)
Definition: Tracer.cc:221
unsigned int maxNumberOfStreams() const
Definition: SystemBounds.h:43
void watchPreOpenFile(PreOpenFile::slot_type const &iSlot)
void watchPostGlobalBeginRun(PostGlobalBeginRun::slot_type const &iSlot)
void watchPostCloseFile(PostCloseFile::slot_type const &iSlot)
void watchPreGlobalEndRun(PreGlobalEndRun::slot_type const &iSlot)
void preGlobalBeginRun(GlobalContext const &)
Definition: Tracer.cc:300
void preSourceEvent(StreamID)
Definition: Tracer.cc:191
void preGlobalEndRun(GlobalContext const &)
Definition: Tracer.cc:322
void watchPostSourceRun(PostSourceRun::slot_type const &iSlot)
void watchPostStreamBeginLumi(PostStreamBeginLumi::slot_type const &iSlot)
void preModuleStreamEndLumi(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:736
Tracer(const ParameterSet &, ActivityRegistry &)
Definition: Tracer.cc:59
void preModuleStreamBeginRun(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:646
void watchPreSourceLumi(PreSourceLumi::slot_type const &iSlot)
void prePathEvent(StreamContext const &, PathContext const &)
Definition: Tracer.cc:498
void watchPreModuleEventDelayedGet(PreModuleEventDelayedGet::slot_type const &iSlot)
ModuleDescription const * moduleDescription() const
void postModuleStreamBeginLumi(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:721
RunNumber_t run() const
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition: Tracer.cc:163
void watchPreModuleEndJob(PreModuleEndJob::slot_type const &iSlot)
void watchPostGlobalEndLumi(PostGlobalEndLumi::slot_type const &iSlot)
void watchPreSourceRun(PreSourceRun::slot_type const &iSlot)
void preModuleGlobalEndRun(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:796
void postStreamBeginRun(StreamContext const &)
Definition: Tracer.cc:355
std::ostream & operator<<(std::ostream &os, SimpleMemoryCheck::SignificantEvent const &se)
Definition: Memory.cc:807
void watchPreModuleBeginJob(PreModuleBeginJob::slot_type const &iSlot)
void preStreamEndRun(StreamContext const &)
Definition: Tracer.cc:366
void watchPostStreamEndRun(PostStreamEndRun::slot_type const &iSlot)
void postOpenFile(std::string const &, bool)
Definition: Tracer.cc:229
void watchPreModuleGlobalBeginLumi(PreModuleGlobalBeginLumi::slot_type const &iSlot)
void watchPostModuleStreamEndRun(PostModuleStreamEndRun::slot_type const &iSlot)
void postPathEvent(StreamContext const &, PathContext const &, HLTPathStatus const &)
Definition: Tracer.cc:509
StreamID const & streamID() const
Definition: StreamContext.h:57
tuple out
Definition: dbtoconf.py:99
void watchPreGlobalBeginRun(PreGlobalBeginRun::slot_type const &iSlot)
void watchPreModuleStreamBeginLumi(PreModuleStreamBeginLumi::slot_type const &iSlot)
void setComment(std::string const &value)
void postModuleEventDelayedGet(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:630
void watchPostModuleBeginStream(PostModuleBeginStream::slot_type const &iSlot)
unsigned int maxNumberOfConcurrentLuminosityBlocks() const
Definition: SystemBounds.h:45
void watchPostSourceLumi(PostSourceLumi::slot_type const &iSlot)
void watchPreCloseFile(PreCloseFile::slot_type const &iSlot)
void watchPostModuleEventDelayedGet(PostModuleEventDelayedGet::slot_type const &iSlot)
void watchPostModuleGlobalEndRun(PostModuleGlobalEndRun::slot_type const &iSlot)
void watchPostModuleStreamBeginLumi(PostModuleStreamBeginLumi::slot_type const &iSlot)
void preSourceLumi()
Definition: Tracer.cc:201
void postSourceEvent(StreamID)
Definition: Tracer.cc:196
std::string indention_
Definition: Tracer.h:145
void watchPreModuleStreamEndLumi(PreModuleStreamEndLumi::slot_type const &iSlot)
void watchPreModuleStreamBeginRun(PreModuleStreamBeginRun::slot_type const &iSlot)
void watchPostGlobalEndRun(PostGlobalEndRun::slot_type const &iSlot)
double b
Definition: hdecay.h:120
LuminosityBlockNumber_t luminosityBlock() const
void watchPreStreamBeginLumi(PreStreamBeginLumi::slot_type const &iSlot)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
void watchPostOpenFile(PostOpenFile::slot_type const &iSlot)
void watchPreModuleEndStream(PreModuleEndStream::slot_type const &iSlot)
void preSourceConstruction(ModuleDescription const &md)
Definition: Tracer.cc:886
void preModuleEvent(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:584
void preModuleBeginStream(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:252
void watchPostStreamBeginRun(PostStreamBeginRun::slot_type const &iSlot)
void postGlobalBeginRun(GlobalContext const &)
Definition: Tracer.cc:311
void postGlobalEndRun(GlobalContext const &)
Definition: Tracer.cc:333
void postGlobalBeginLumi(GlobalContext const &)
Definition: Tracer.cc:399
void watchPreStreamBeginRun(PreStreamBeginRun::slot_type const &iSlot)
void watchPreModuleStreamEndRun(PreModuleStreamEndRun::slot_type const &iSlot)
void preEvent(StreamContext const &)
Definition: Tracer.cc:476
void watchPostModuleBeginJob(PostModuleBeginJob::slot_type const &iSlot)
void watchPostModuleGlobalBeginRun(PostModuleGlobalBeginRun::slot_type const &iSlot)
unsigned int maxNumberOfConcurrentRuns() const
Definition: SystemBounds.h:44
void preStreamBeginLumi(StreamContext const &)
Definition: Tracer.cc:432
void postModuleEndJob(ModuleDescription const &md)
Definition: Tracer.cc:573
void preModuleEndStream(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:276
void postModuleEvent(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:599
EventID const & eventID() const
Definition: StreamContext.h:59
void preModuleEventDelayedGet(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:615
void watchPreSourceEvent(PreSourceEvent::slot_type const &iSlot)
void postModuleBeginStream(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:264
bool dumpNonModuleContext_
Definition: Tracer.h:147
void preModuleBeginJob(ModuleDescription const &md)
Definition: Tracer.cc:540
void postStreamEndLumi(StreamContext const &)
Definition: Tracer.cc:465
void preModuleStreamEndRun(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:676
void postEvent(StreamContext const &)
Definition: Tracer.cc:487
void preStreamBeginRun(StreamContext const &)
Definition: Tracer.cc:344
TimeValue_t value() const
Definition: Timestamp.h:56
void watchPostModuleEndJob(PostModuleEndJob::slot_type const &iSlot)
void postModuleStreamBeginRun(StreamContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:661
void postSourceLumi()
Definition: Tracer.cc:206
void preGlobalBeginLumi(GlobalContext const &)
Definition: Tracer.cc:388
void watchPreModuleGlobalEndLumi(PreModuleGlobalEndLumi::slot_type const &iSlot)
void postModuleGlobalEndRun(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:811
unsigned int id() const
void postSourceConstruction(ModuleDescription const &md)
Definition: Tracer.cc:897
std::set< std::string > dumpContextForLabels_
Definition: Tracer.h:146
void preModuleGlobalBeginRun(GlobalContext const &, ModuleCallingContext const &)
Definition: Tracer.cc:766
void watchPostBeginJob(PostBeginJob::slot_type const &iSlot)
convenience function for attaching to signal
Timestamp const & timestamp() const
Definition: StreamContext.h:62