Electroneum
Loading...
Searching...
No Matches
perf_timer.cpp File Reference
#include <vector>
#include "misc_os_dependent.h"
#include "perf_timer.h"
Include dependency graph for perf_timer.cpp:

Go to the source code of this file.

Namespaces

namespace  tools
 Various Tools.

Macros

#define ELECTRONEUM_DEFAULT_LOG_CATEGORY   "perf"
#define PERF_LOG_ALWAYS(level, cat, x)
#define PERF_LOG(level, cat, x)

Functions

uint64_t tools::get_tick_count ()
uint64_t tools::ticks_to_ns (uint64_t ticks)
void tools::set_performance_timer_log_level (el::Level level)

Variables

el::Level tools::performance_timer_log_level = el::Level::Info

Macro Definition Documentation

◆ ELECTRONEUM_DEFAULT_LOG_CATEGORY

#define ELECTRONEUM_DEFAULT_LOG_CATEGORY   "perf"

Definition at line 35 of file perf_timer.cpp.

◆ PERF_LOG

#define PERF_LOG ( level,
cat,
x )
Value:
do { \
if (ELPP->vRegistry()->allowed(level, cat)) PERF_LOG_ALWAYS(level, cat, x); \
} while(0)
#define ELPP
#define PERF_LOG_ALWAYS(level, cat, x)

Definition at line 39 of file perf_timer.cpp.

39#define PERF_LOG(level, cat, x) \
40 do { \
41 if (ELPP->vRegistry()->allowed(level, cat)) PERF_LOG_ALWAYS(level, cat, x); \
42 } while(0)

◆ PERF_LOG_ALWAYS

#define PERF_LOG_ALWAYS ( level,
cat,
x )
Value:
Main entry point of each logging.
Writer & construct(Logger *logger, bool needLock=true)
#define ELPP_FUNC

Definition at line 37 of file perf_timer.cpp.

37#define PERF_LOG_ALWAYS(level, cat, x) \
38 el::base::Writer(level, __FILE__, __LINE__, ELPP_FUNC, el::base::DispatchAction::FileOnlyLog).construct(cat) << x