45 void add(
const std::string &name,
float value);
46 void avg(
const std::string &name,
float value);
49 float getValue(
const std::string &name)
const;
56 int print(std::ostream &o, u32 page = 1, u32 pagecount = 1);
60 void graphAdd(
const std::string &
id,
float value)
63 std::map<std::string, float>::iterator i =
Definition: profiler.h:41
u64 m_start_time
Definition: profiler.h:89
std::map< std::string, float > m_data
Definition: profiler.h:86
void graphAdd(const std::string &id, float value)
Definition: profiler.h:60
void getPage(GraphValues &o, u32 page, u32 pagecount)
Definition: profiler.cpp:163
void avg(const std::string &name, float value)
Definition: profiler.cpp:86
void add(const std::string &name, float value)
Definition: profiler.cpp:63
void remove(const std::string &name)
Definition: profiler.h:77
int getAvgCount(const std::string &name) const
Definition: profiler.cpp:121
Profiler()
Definition: profiler.cpp:58
void clear()
Definition: profiler.cpp:96
std::map< std::string, int > m_avgcounts
Definition: profiler.h:87
float getValue(const std::string &name) const
Definition: profiler.cpp:106
std::mutex m_mutex
Definition: profiler.h:85
u64 getElapsedMs() const
Definition: profiler.cpp:131
int print(std::ostream &o, u32 page=1, u32 pagecount=1)
Definition: profiler.cpp:136
std::map< std::string, float > m_graphvalues
Definition: profiler.h:88
void graphGet(GraphValues &result)
Definition: profiler.h:70
std::map< std::string, float > GraphValues
Definition: profiler.h:53
Definition: profiler.h:99
~ScopeProfiler()
Definition: profiler.cpp:35
std::string m_name
Definition: profiler.h:106
ScopeProfiler(Profiler *profiler, const std::string &name, ScopeProfilerType type=SPT_ADD)
Definition: profiler.cpp:25
Profiler * m_profiler
Definition: profiler.h:105
TimeTaker * m_timer
Definition: profiler.h:107
enum ScopeProfilerType m_type
Definition: profiler.h:108
std::unique_lock< std::mutex > MutexAutoLock
Definition: mutex_auto_lock.h:29
Profiler * g_profiler
Definition: profiler.cpp:24
ScopeProfilerType
Definition: profiler.h:92
@ SPT_AVG
Definition: profiler.h:94
@ SPT_ADD
Definition: profiler.h:93
@ SPT_GRAPH_ADD
Definition: profiler.h:95