View Issue Details

IDProjectCategoryView StatusLast Update
0004504Open CASCADEOCCT:Data Exchangepublic2012-01-17 17:35
ReporterpdnAssigned Toskl 
PrioritynormalSeverityfeature 
Status closedResolutionfixed 
OSAll 
Fixed in Version5.1.2 
Summary0004504: Integration of perf meter
DescriptionTool intended to measuring of performance of ShapeHealing and DE modules
Additional information
and documentation updates
Documentation remark, added by ATP 2004-02-11 10:57:07:

Improvements:
Timers are used for measuring the perfomance of current operation or any part of
code, and provide amount of calls of operation.
Timers are used for debugging purposes and optimising perfomance.

More information you can find in the corresponding .cdl files (see list of new
classes in the "List of modified entities").

Example (can use in the Users Guide):
Using timers in XSDRAWIGES.cxx and IGESBRep_Reader.cxx for
analysis performance command "igesbrep":

XSDRAWIGES.cxx
  ...
  #include <MoniTool_Timer.hxx>
  #include <MoniTool_TimerSentry.hxx>
  ...
  MoniTool_Timer::ClearTimers();
  ...
  MoniTool_TimerSentry MTS("IGES_LoadFile");
  Standard_Integer status = Reader.LoadFile(fnom.ToCString());
  MTS.Stop();
  ...
  MoniTool_Timer::DumpTimers(cout);
  return;
                                                                                
                        
IGESBRep_Reader.cxx
  ...
  #include <MoniTool_TimerSentry.hxx>
  ...
  Standard_Integer nb = theModel->NbEntities();
  ...
  for (Standard_Integer i=1; i<=nb; i++) {
    MoniTool_TimerSentry MTS("IGESToBRep_Transfer");
    ...
    try {
      TP.Transfer(ent);
      shape = TransferBRep::ShapeResult (theProc,ent);
    }
    ...
  }

Result DumpTimer() after translation file:

 TIMER: IGES_LoadFile Elapsed: 1.0 sec, CPU User: 0.9 sec, CPU
Sys: 0.0 sec, hits: 1
 TIMER: IGESToBRep_Transfer Elapsed: 14.5 sec, CPU User: 4.4 sec, CPU
Sys: 0.1 sec, hits: 1311

Modified entities:
New classes:
MoniTool_Timer
  Provides convenient service on global timers accessed by string name,
  mostly aimed for debugging purposes.
  As an instance, envelopes the OSD_Timer to have it as Handle
  As a tool, supports static map of timers and provides static methods
  to easily access them.
MoniTool_TimerSentry
  A tool to facilitate using MoniTool_Timer functionality by
  automatically ensuring consistency of start/stop actions.
  When instance of TimerSentry is created, a timer with corresponding
  name is started, when instance is deleted, timer stops.

Internal - not for Reference Doc:
MoniTool_MTHasher
  The auxiliary class provides hash code for mapping timers.
TagsNo tags attached.
Test case number

Attached Files

  • PerfTimer.tar (61,440 bytes)

Activities

2003-11-25 07:08

 

PerfTimer.tar (61,440 bytes)

Issue History

Date Modified Username Field Change
2003-11-25 10:20 bugmaster Assigned To bugmaster => skl
2003-11-25 10:20 bugmaster Status new => assigned
2003-12-10 12:50 bugmaster CC => apv
2003-12-10 17:28 apv CC => aki
2003-12-23 10:09 bugmaster Category => DOC
2003-12-23 10:09 bugmaster QAContact in development version => bugmaster
2003-12-26 11:06 bugmaster Status assigned => tested
2004-01-13 11:37 bugmaster Status tested => closed
2004-01-13 11:37 bugmaster Fixed in Version => 5.1.2
2004-01-13 11:37 bugmaster Resolution @0@ => fixed
2004-02-19 11:19 bugmaster Category => DTE
2004-02-19 11:19 bugmaster QAContact in development version => aki
2011-08-02 11:12 bugmaster Category OCCT:DTE => OCCT:Data Exchange
2012-01-17 17:35 atp Additional Information Updated