[PATCH V1 21/23] libperf evsel: Add comments for booleans

From: Adrian Hunter
Date: Thu May 05 2022 - 12:59:24 EST


Add comments for 'system_wide' and 'requires_cpu' booleans

Signed-off-by: Adrian Hunter <adrian.hunter@xxxxxxxxx>
---
tools/lib/perf/include/internal/evsel.h | 8 ++++++++
1 file changed, 8 insertions(+)

diff --git a/tools/lib/perf/include/internal/evsel.h b/tools/lib/perf/include/internal/evsel.h
index 77fbb8b97e5c..f613c3ae868e 100644
--- a/tools/lib/perf/include/internal/evsel.h
+++ b/tools/lib/perf/include/internal/evsel.h
@@ -49,7 +49,15 @@ struct perf_evsel {

/* parse modifier helper */
int nr_members;
+ /*
+ * system_wide is for events that need to be on every CPU, irrespective
+ * of user requested CPUs or threads.
+ */
bool system_wide;
+ /*
+ * Some events, for example uncore events, require a CPU.
+ * i.e. it cannot be -1
+ */
bool requires_cpu;
int idx;
};
--
2.25.1