Re: [PATCH 2/3] perf tools: Allow to enable/disable events via control file

Arnaldo Carvalho de Melo
2020-12-15T16:27:59Z

Em Tue, Dec 15, 2020 at 05:18:38PM +0100, Jiri Olsa escreveu:
> On Tue, Dec 15, 2020 at 01:03:32PM -0300, Arnaldo Carvalho de Melo wrote:
> > I see it, but why not use the more natural ' ' space to separate the
> > command from its arguments? Just like in a bash command line, say?

> > I.e. why not:

> > enable

> > to enable everything, and:

> > enable sched:sched_switch

> > To enable just the "sched:sched_switch" event?

> right, that's we discussed in the other patch thread,
> I'll make the change

This is a new way to control perf, its important that we try to reuse
the same concepts as in the pre-existing forms of interaction, so as to
reduce the learning curve for using this control mode.

I.e. this 'enable' should be as equivalent to the -e argument as
possible, for what makes sense for a pre-existing, already configured
event.

For _adding_ new ones, that we probably will want next, then its even
more important to reuse the same -e parser :-)

Thanks!

- Arnaldo