Skip to content

Commit 5f8f956

Browse files
captain5050acmel
authored andcommitted
perf evlist: Remove group option.
The group option predates grouping events using curly braces added in commit 89efb02 ("perf tools: Add support to parse event group syntax"). The --group option was retained for legacy support (in August 2012) but keeping it adds complexity. Signed-off-by: Ian Rogers <[email protected]> Cc: Adrian Hunter <[email protected]> Cc: Alexander Shishkin <[email protected]> Cc: Alexey Bayduraev <[email protected]> Cc: Andi Kleen <[email protected]> Cc: Anshuman Khandual <[email protected]> Cc: Athira Jajeev <[email protected]> Cc: Eelco Chaudron <[email protected]> Cc: German Gomez <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: James Clark <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Kan Liang <[email protected]> Cc: Kim Phillips <[email protected]> Cc: Leo Yan <[email protected]> Cc: Mark Rutland <[email protected]> Cc: Namhyung Kim <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Riccardo Mancini <[email protected]> Cc: Sandipan Das <[email protected]> Cc: Sean Christopherson <[email protected]> Cc: Shaomin Deng <[email protected]> Cc: Stephane Eranian <[email protected]> Cc: Timothy Hayes <[email protected]> Cc: Xing Zhengjun <[email protected]> Cc: [email protected] Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent caec547 commit 5f8f956

File tree

13 files changed

+3
-79
lines changed

13 files changed

+3
-79
lines changed

tools/perf/Documentation/perf-record.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -238,10 +238,6 @@ OPTIONS
238238
Also, by adding a comma, the number of mmap pages for AUX
239239
area tracing can be specified.
240240

241-
--group::
242-
Put all events in a single event group. This precedes the --event
243-
option and remains only for backward compatibility. See --event.
244-
245241
-g::
246242
Enables call-graph (stack chain/backtrace) recording for both
247243
kernel space and user space.

tools/perf/Documentation/perf-top.txt

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,6 @@ Default is to monitor all CPUS.
5151
--count-filter=<count>::
5252
Only display functions with more events than this.
5353

54-
--group::
55-
Put the counters into a counter group.
56-
5754
--group-sort-idx::
5855
Sort the output by the event at the index n in group. If n is invalid,
5956
sort by the first event. It can support multiple groups with different
@@ -313,10 +310,10 @@ use '-e e1 -e e2 -G foo,foo' or just use '-e e1 -e e2 -G foo'.
313310

314311
perf top -e cycles,probe:icmp_rcv --switch-on=probe:icmp_rcv
315312

316-
Alternatively one can ask for --group and then two overhead columns
313+
Alternatively one can ask for a group and then two overhead columns
317314
will appear, the first for cycles and the second for the switch-on event.
318315

319-
perf top --group -e cycles,probe:icmp_rcv --switch-on=probe:icmp_rcv
316+
perf top -e '{cycles,probe:icmp_rcv}' --switch-on=probe:icmp_rcv
320317

321318
This may be interesting to measure a workload only after some initialization
322319
phase is over, i.e. insert a perf probe at that point and use the above

tools/perf/builtin-record.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3380,8 +3380,6 @@ static struct option __record_options[] = {
33803380
OPT_CALLBACK(0, "mmap-flush", &record.opts, "number",
33813381
"Minimal number of bytes that is extracted from mmap data pages (default: 1)",
33823382
record__mmap_flush_parse),
3383-
OPT_BOOLEAN(0, "group", &record.opts.group,
3384-
"put the counters into a counter group"),
33853383
OPT_CALLBACK_NOOPT('g', NULL, &callchain_param,
33863384
NULL, "enables call-graph recording" ,
33873385
&record_callchain_opt),

tools/perf/builtin-stat.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,6 @@ static bool topdown_run = false;
181181
static bool smi_cost = false;
182182
static bool smi_reset = false;
183183
static int big_num_opt = -1;
184-
static bool group = false;
185184
static const char *pre_cmd = NULL;
186185
static const char *post_cmd = NULL;
187186
static bool sync_run = false;
@@ -781,9 +780,6 @@ static int __run_perf_stat(int argc, const char **argv, int run_idx)
781780
child_pid = evsel_list->workload.pid;
782781
}
783782

784-
if (group)
785-
evlist__set_leader(evsel_list);
786-
787783
if (!cpu_map__is_dummy(evsel_list->core.user_requested_cpus)) {
788784
if (affinity__setup(&saved_affinity) < 0)
789785
return -1;
@@ -1192,8 +1188,6 @@ static struct option stat_options[] = {
11921188
#endif
11931189
OPT_BOOLEAN('a', "all-cpus", &target.system_wide,
11941190
"system-wide collection from all CPUs"),
1195-
OPT_BOOLEAN('g', "group", &group,
1196-
"put the counters into a counter group"),
11971191
OPT_BOOLEAN(0, "scale", &stat_config.scale,
11981192
"Use --no-scale to disable counter scaling for multiplexing"),
11991193
OPT_INCR('v', "verbose", &verbose,

tools/perf/builtin-top.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1471,8 +1471,6 @@ int cmd_top(int argc, const char **argv)
14711471
"dump the symbol table used for profiling"),
14721472
OPT_INTEGER('f', "count-filter", &top.count_filter,
14731473
"only display functions with more events than this"),
1474-
OPT_BOOLEAN(0, "group", &opts->group,
1475-
"put the counters into a counter group"),
14761474
OPT_BOOLEAN('i', "no-inherit", &opts->no_inherit,
14771475
"child tasks do not inherit counters"),
14781476
OPT_STRING(0, "sym-annotate", &top.sym_filter, "symbol name",

tools/perf/tests/attr/README

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ Following tests are defined (with perf commands):
4949
perf record --call-graph dwarf kill (test-record-graph-dwarf)
5050
perf record --call-graph fp kill (test-record-graph-fp)
5151
perf record --call-graph fp kill (test-record-graph-fp-aarch64)
52-
perf record --group -e cycles,instructions kill (test-record-group)
5352
perf record -e '{cycles,instructions}' kill (test-record-group1)
5453
perf record -e '{cycles/period=1/,instructions/period=2/}:S' kill (test-record-group2)
5554
perf record -D kill (test-record-no-delay)
@@ -66,6 +65,5 @@ Following tests are defined (with perf commands):
6665
perf stat -d kill (test-stat-detailed-1)
6766
perf stat -dd kill (test-stat-detailed-2)
6867
perf stat -ddd kill (test-stat-detailed-3)
69-
perf stat --group -e cycles,instructions kill (test-stat-group)
7068
perf stat -e '{cycles,instructions}' kill (test-stat-group1)
7169
perf stat -i -e cycles kill (test-stat-no-inherit)

tools/perf/tests/attr/test-record-group

Lines changed: 0 additions & 22 deletions
This file was deleted.

tools/perf/tests/attr/test-stat-group

Lines changed: 0 additions & 17 deletions
This file was deleted.

tools/perf/util/evlist.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ int __evlist__set_tracepoints_handlers(struct evlist *evlist,
230230
return err;
231231
}
232232

233-
void evlist__set_leader(struct evlist *evlist)
233+
static void evlist__set_leader(struct evlist *evlist)
234234
{
235235
perf_evlist__set_leader(&evlist->core);
236236
}

tools/perf/util/evlist.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,8 +221,6 @@ void evlist__set_selected(struct evlist *evlist, struct evsel *evsel);
221221
int evlist__create_maps(struct evlist *evlist, struct target *target);
222222
int evlist__apply_filters(struct evlist *evlist, struct evsel **err_evsel);
223223

224-
void evlist__set_leader(struct evlist *evlist);
225-
226224
u64 __evlist__combined_sample_type(struct evlist *evlist);
227225
u64 evlist__combined_sample_type(struct evlist *evlist);
228226
u64 evlist__combined_branch_type(struct evlist *evlist);

0 commit comments

Comments
 (0)