4 #ifndef WIRECELL_MEMUSAGE 5 #define WIRECELL_MEMUSAGE 22 typedef std::pair<memusage, std::string>
event;
void msg(const char *fmt,...)
std::string operator()(std::string msg="<tick>", MemUsage::memusage mu=memusage(-1,-1))
Record an event.
std::pair< memusage, std::string > event
double memusage_resident()
std::pair< double, double > memusage
std::string emit(int ind) const
Emit a formatted message for the given event index.
void push(const std::string &msg, MemUsage::memusage mu=memusage(-1,-1))
std::string summary() const
Return summary up to now.
MemUsage(const std::string &msg="start")
std::vector< event > m_events
event operator[](int ind) const
Return event by index.