45 if(nbThread < 1lu){nbThread = 1;}
103 out <<
"function,nbCall,fullTime,averageTime,stdTime,minTime,maxTime" << std::endl;
Performances of a function.
void resize(size_t nbThread)
Resize the PFunctionPerf by respect to the number of thread which call the function.
void initialisationPProfiler()
Initialisation function of the class PProfiler.
void printCsvHeader(std::ostream &out=std::cout) const
Print header of all the PFunctionPerf of the PProfiler in CSV format.
void start(size_t index, size_t threadIndex=0lu)
Start the given PFunctionPerf.
PProfiler()
Default constructor of PProfiler.
void print(std::ostream &out=std::cout) const
Print all the PFunctionPerf of the PProfiler.
void printCsv(std::ostream &out=std::cout) const
Print all the PFunctionPerf of the PProfiler in CSV format.
void copyPProfiler(const PProfiler &other)
Copy function of PProfiler.
void rename(size_t index, const std::string &name)
Rename a function.
PProfiler & operator=(const PProfiler &other)
Definition of equal operator of PProfiler.
virtual ~PProfiler()
Destructor of PProfiler.
size_t addFunction(const std::string &name, size_t nbThread=1lu)
Add a function to profile.
void reset()
Reset all the function perf.
PVecFunctionPerf p_vecFunctionPerf
Vector of performances for all registered functions.
void stop(size_t index, size_t threadIndex=0lu)
Stop the given PFunctionPerf.