[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z5Ld5irdG--_Efgl@google.com>
Date: Thu, 23 Jan 2025 16:25:10 -0800
From: Namhyung Kim <namhyung@...nel.org>
To: Aaron Tomlin <atomlin@...mlin.com>
Cc: peterz@...radead.org, mingo@...hat.com, acme@...nel.org,
mark.rutland@....com, alexander.shishkin@...ux.intel.com,
jolsa@...nel.org, irogers@...gle.com, adrian.hunter@...el.com,
kan.liang@...ux.intel.com, linux-perf-users@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] perf probe: Introduce --no-advice option when a new
event is created
Hello,
Sorry for the late reply.
On Sat, Dec 14, 2024 at 07:34:52PM +0000, Aaron Tomlin wrote:
> This patch introduces a new option namely "--no-advice" to be used with
> the add command. Now one has the ability to avoid the generation of any
> advice when a new event is created. Thus making the output reasonable.
> For example:
>
> # perf probe --no-advice --add 'user_path_at%return return=$retval:s32'
> Added new event:
> probe:user_path_at__return (on user_path_at%return with return=$retval:s32)
> #
Thanks for sending the patch but why do you care? You can just ignore
the message.
Thanks,
Namhyung
>
> Signed-off-by: Aaron Tomlin <atomlin@...mlin.com>
> ---
> tools/perf/builtin-probe.c | 4 +++-
> tools/perf/util/probe-event.h | 1 +
> 2 files changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/tools/perf/builtin-probe.c b/tools/perf/builtin-probe.c
> index 69800e4d9530..36b8e08f3725 100644
> --- a/tools/perf/builtin-probe.c
> +++ b/tools/perf/builtin-probe.c
> @@ -391,7 +391,7 @@ static int perf_add_probe_events(struct perf_probe_event *pevs, int npevs)
> }
>
> /* Note that it is possible to skip all events because of blacklist */
> - if (event) {
> + if (event && !probe_conf.no_advice) {
> #ifndef HAVE_LIBTRACEEVENT
> pr_info("\nperf is not linked with libtraceevent, to use the new probe you can use tracefs:\n\n");
> pr_info("\tcd /sys/kernel/tracing/\n");
> @@ -577,6 +577,8 @@ __cmd_probe(int argc, const char **argv)
> "directory", "path to kernel source"),
> OPT_BOOLEAN('\0', "no-inlines", &probe_conf.no_inlines,
> "Don't search inlined functions"),
> + OPT_BOOLEAN('\0', "no-advice", &probe_conf.no_advice,
> + "Don't provide any advice after a new event is created."),
> OPT__DRY_RUN(&probe_event_dry_run),
> OPT_INTEGER('\0', "max-probes", &probe_conf.max_probes,
> "Set how many probe points can be found for a probe."),
> diff --git a/tools/perf/util/probe-event.h b/tools/perf/util/probe-event.h
> index 61a5f4ff4e9c..be0dce26e133 100644
> --- a/tools/perf/util/probe-event.h
> +++ b/tools/perf/util/probe-event.h
> @@ -14,6 +14,7 @@ struct probe_conf {
> bool show_location_range;
> bool force_add;
> bool no_inlines;
> + bool no_advice;
> bool cache;
> bool bootconfig;
> int max_probes;
> --
> 2.47.1
>
Powered by blists - more mailing lists