Perf: Add support for L2 cycle counter in default list
Adding the L2 cycle counter in the default list of events has the advantage that the user can do a : perf stat -e l2-cycles -e cycles ls and see the outputs for the L2 cycle counter and L1 cycle counter separately. Previously, it was only accessible via the raw code "rsfe". This method also allows us to program the L2 cycle counter only from one CPU. The changes in this patch are used by the userspace perf tool. Change-Id: I61b85b48f5474fe9f6ffb1a405b60b4332ab60c7 Signed-off-by: Ashwin Chaugule <ashwinc@codeaurora.org>
This commit is contained in:
committed by
Neil Leeder
parent
a9b96e1ba3
commit
389497b245
@@ -55,6 +55,7 @@ enum perf_hw_id {
|
||||
PERF_COUNT_HW_BUS_CYCLES = 6,
|
||||
PERF_COUNT_HW_STALLED_CYCLES_FRONTEND = 7,
|
||||
PERF_COUNT_HW_STALLED_CYCLES_BACKEND = 8,
|
||||
PERF_COUNT_HW_L2_CYCLES = 9,
|
||||
|
||||
PERF_COUNT_HW_MAX, /* non-ABI */
|
||||
};
|
||||
@@ -219,8 +220,9 @@ struct perf_event_attr {
|
||||
precise_ip : 2, /* skid constraint */
|
||||
mmap_data : 1, /* non-exec mmap data */
|
||||
sample_id_all : 1, /* sample_type all events */
|
||||
single_instance:1, /* per-cpu event if unset */
|
||||
|
||||
__reserved_1 : 45;
|
||||
__reserved_1:44;
|
||||
|
||||
union {
|
||||
__u32 wakeup_events; /* wakeup every n events */
|
||||
|
||||
Reference in New Issue
Block a user