mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 23:21:59 +00:00
Add perf metric for NUMA-local memory access
This commit is contained in:
parent
97e8a88b30
commit
5a662ca48c
@ -202,6 +202,8 @@
|
||||
M(PerfDataTLBMisses, "Data TLB misses") \
|
||||
M(PerfInstructionTLBReferences, "Instruction TLB references") \
|
||||
M(PerfInstructionTLBMisses, "Instruction TLB misses") \
|
||||
M(PerfLocalMemoryReferences, "Local node memory reads") \
|
||||
M(PerfLocalMemoryMisses, "Local node memory read misses") \
|
||||
\
|
||||
M(CreatedHTTPConnections, "Total amount of created HTTP connections (closed or opened).") \
|
||||
\
|
||||
|
@ -193,12 +193,16 @@ static const PerfEventInfo raw_events_info[] = {
|
||||
// https://stackoverflow.com/questions/49933319/how-to-interpret-perf-itlb-loads-itlb-load-misses
|
||||
CACHE_EVENT(PERF_COUNT_HW_CACHE_ITLB, PerfInstructionTLBReferences, ACCESS),
|
||||
CACHE_EVENT(PERF_COUNT_HW_CACHE_ITLB, PerfInstructionTLBMisses, MISS),
|
||||
|
||||
CACHE_EVENT(PERF_COUNT_HW_CACHE_NODE, PerfLocalMemoryReferences, ACCESS),
|
||||
CACHE_EVENT(PERF_COUNT_HW_CACHE_NODE, PerfLocalMemoryMisses, MISS),
|
||||
};
|
||||
|
||||
static_assert(sizeof(raw_events_info) / sizeof(raw_events_info[0]) == NUMBER_OF_RAW_EVENTS);
|
||||
|
||||
#undef HARDWARE_EVENT
|
||||
#undef SOFTWARE_EVENT
|
||||
#undef CACHE_EVENT
|
||||
|
||||
// A map of event name -> event index, to parse event list in settings.
|
||||
static std::unordered_map<std::string, size_t> populateEventMap()
|
||||
|
@ -59,6 +59,8 @@ namespace ProfileEvents
|
||||
extern const Event PerfDataTLBMisses;
|
||||
extern const Event PerfInstructionTLBReferences;
|
||||
extern const Event PerfInstructionTLBMisses;
|
||||
extern const Event PerfLocalMemoryReferences;
|
||||
extern const Event PerfLocalMemoryMisses;
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -162,7 +164,7 @@ struct PerfEventValue
|
||||
UInt64 time_running = 0;
|
||||
};
|
||||
|
||||
static constexpr size_t NUMBER_OF_RAW_EVENTS = 20;
|
||||
static constexpr size_t NUMBER_OF_RAW_EVENTS = 22;
|
||||
|
||||
struct PerfDescriptorsHolder : boost::noncopyable
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user