[sysprof] sources/perf: Add a comment explaining sp-perf-counter structs.



commit 380995fde5f36a9d4e2eb3dfb8e409b71fe0e421
Author: Eric Anholt <eric anholt net>
Date:   Wed May 16 09:37:39 2018 +0100

    sources/perf: Add a comment explaining sp-perf-counter structs.

 lib/sources/sp-perf-counter.h |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/lib/sources/sp-perf-counter.h b/lib/sources/sp-perf-counter.h
index c97eb0c..213aff3 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;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]