Go to the documentation of this file.
   38 #ifndef FCL_COMMON_DETAIL_PROFILER_H 
   39 #define FCL_COMMON_DETAIL_PROFILER_H 
   52 #include "fcl/export.h" 
   71   class FCL_EXPORT ScopedBlock;
 
   77   class FCL_EXPORT ScopedStart;
 
   84   Profiler(
bool printOnDestroy = 
false, 
bool autoStart = 
false);
 
   90   static void Start(
void);
 
   93   static void Stop(
void);
 
   96   static void Clear(
void);
 
  108   static void Event(
const std::string& 
name, 
const unsigned int times = 1);
 
  111   void event(
const std::string &
name, 
const unsigned int times = 1);
 
  114   static void Average(
const std::string& 
name, 
const double value);
 
  117   void average(
const std::string &
name, 
const double value);
 
  120   static void Begin(
const std::string &
name);
 
  123   static void End(
const std::string &
name);
 
  126   void begin(
const std::string &
name);
 
  129   void end(
const std::string &
name);
 
  134   static void Status(std::ostream &out = std::cout, 
bool merge = 
true);
 
  139   void status(std::ostream &out = std::cout, 
bool merge = 
true);
 
  142   bool running(
void) 
const;
 
  145   static bool Running(
void);
 
  193     std::map<std::string, unsigned long int> 
events;
 
  196     std::map<std::string, AvgInfo>           
avg;
 
  199     std::map<std::string, TimeInfo>          
time;
 
  202   void printThreadInfo(std::ostream &out, 
const PerThread &data);
 
  205   std::map<std::thread::id, PerThread>   
data_;
 
  214 class FCL_EXPORT 
Profiler::ScopedBlock
 
  233 class FCL_EXPORT 
Profiler::ScopedStart
 
  251 #endif // #ifndef FCL_COMMON_DETAIL_PROFILER_H 
  
std::chrono::system_clock::duration duration
Representation of a time duration.
time::duration total
Total time counted.
std::map< std::string, AvgInfo > avg
The stored averages.
unsigned long int parts
Number of times a value was added to this structure.
Information maintained about averaged values.
std::map< std::thread::id, PerThread > data_
double totalSqr
The sub of squares of the values to average.
time::duration shortest
The shortest counted time interval.
time::point start
The point in time when counting time started.
double total
The sum of the values to average.
static Profiler & Instance(void)
Return an instance of the class.
std::map< std::string, TimeInfo > time
The amount of time spent in various places.
unsigned long int parts
Number of times a chunk of time was added to this structure.
Information about time spent in a section of the code.
std::chrono::system_clock::time_point point
Representation of a point in time.
std::map< std::string, unsigned long int > events
The stored events.
Information to be maintained for each thread.
This is a simple thread-safe tool for counting time spent in various chunks of code....
time::duration longest
The longest counted time interval.
fcl
Author(s): 
autogenerated on Fri Mar 14 2025 02:38:18