From 380995fde5f36a9d4e2eb3dfb8e409b71fe0e421 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Wed, 16 May 2018 09:37:39 +0100 Subject: [PATCH] sources/perf: Add a comment explaining sp-perf-counter structs. --- lib/sources/sp-perf-counter.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/sources/sp-perf-counter.h b/lib/sources/sp-perf-counter.h index c97eb0c8..213aff3c 100644 --- a/lib/sources/sp-perf-counter.h +++ b/lib/sources/sp-perf-counter.h @@ -25,6 +25,14 @@ G_BEGIN_DECLS +/* Structs representing the layouts of perf records returned by the + * kernel. + * + * perf returns variable-layout structs based on the + * perf_event_sample_format selectors in perf_event_attr.sample_type. + * These structs are the particular layouts that sysprof requests. + */ + #define SP_TYPE_PERF_COUNTER (sp_perf_counter_get_type()) typedef struct _SpPerfCounter SpPerfCounter;