All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: Howard Chu <howardchu95@gmail.com>
Cc: Arnaldo Carvalho de Melo <arnaldo.melo@gmail.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Ian Rogers <irogers@google.com>, Jiri Olsa <jolsa@kernel.org>,
	Kan Liang <kan.liang@linux.intel.com>,
	Namhyung Kim <namhyung@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	linux-perf-users@vger.kernel.org
Subject: Re: [PATCH 1/1] perf trace: Support collecting 'union's with the BPF augmenter
Date: Tue, 10 Sep 2024 17:31:15 -0300	[thread overview]
Message-ID: <ZuCsk9vnCN5BrCUi@x1> (raw)
In-Reply-To: <ZuCr7yOQb-1qeuox@x1>

On Tue, Sep 10, 2024 at 05:28:34PM -0300, Arnaldo Carvalho de Melo wrote:
> On Tue, Sep 10, 2024 at 09:16:56AM -0700, Howard Chu wrote:
> > Hello Arnaldo,
> > 
> > LGTM.
> 
> Taking that as an Acked-by, as per the Documentation/  submitting
> patches docs, next time consider providing an:
> > On Tue, Sep 10, 2024 at 6:27 AM Arnaldo Carvalho de Melo
> > <arnaldo.melo@gmail.com> wrote:
> > > @@ -2365,8 +2365,7 @@ static size_t syscall__scnprintf_args(struct syscall *sc, char *bf, size_t size,
> > >                         default_scnprintf = sc->arg_fmt[arg.idx].scnprintf;
> > >
> > >                         if (trace->force_btf ||
> > > -                           (default_scnprintf == NULL ||
> > > -                            (default_scnprintf == SCA_PTR && strstr(field->type, "struct")))) {
> > > +                           (default_scnprintf == NULL || (default_scnprintf == SCA_PTR))) {
> > 
> > Can we discard the parenthesis surrounding the 'default_scnprintf == SCA_PTR'?
> > 
> > (default_scnprintf == NULL || default_scnprintf == SCA_PTR)) {

Done:

diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index d28a56cc171b2b2e..ed4c5e637e24eed0 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -2364,8 +2364,7 @@ static size_t syscall__scnprintf_args(struct syscall *sc, char *bf, size_t size,
 
 			default_scnprintf = sc->arg_fmt[arg.idx].scnprintf;
 
-			if (trace->force_btf ||
-			    (default_scnprintf == NULL || (default_scnprintf == SCA_PTR))) {
+			if (trace->force_btf || default_scnprintf == NULL || default_scnprintf == SCA_PTR) {
 				btf_printed = trace__btf_scnprintf(trace, &arg, bf + printed,
 								   size - printed, val, field->type);
 				if (btf_printed) {

  reply	other threads:[~2024-09-10 20:31 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-10 13:27 [PATCH 1/1] perf trace: Support collecting 'union's with the BPF augmenter Arnaldo Carvalho de Melo
2024-09-10 13:36 ` Arnaldo Carvalho de Melo
2024-09-10 13:40   ` Arnaldo Carvalho de Melo
2024-09-10 16:16 ` Howard Chu
2024-09-10 20:28   ` Arnaldo Carvalho de Melo
2024-09-10 20:31     ` Arnaldo Carvalho de Melo [this message]
2024-09-11  7:29     ` Howard Chu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZuCsk9vnCN5BrCUi@x1 \
    --to=acme@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=arnaldo.melo@gmail.com \
    --cc=howardchu95@gmail.com \
    --cc=irogers@google.com \
    --cc=jolsa@kernel.org \
    --cc=kan.liang@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=namhyung@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.