linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Nathan Chancellor <natechancellor@gmail.com>
Cc: Nick Desaulniers <ndesaulniers@google.com>,
	Jason Gunthorpe <jgg@ziepe.ca>,
	Masahiro Yamada <masahiroy@kernel.org>,
	Michal Marek <michal.lkml@markovi.net>,
	Arnd Bergmann <arnd@arndb.de>, Ingo Molnar <mingo@redhat.com>,
	Jason Baron <jbaron@akamai.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Linux Kbuild mailing list <linux-kbuild@vger.kernel.org>,
	linux-arch <linux-arch@vger.kernel.org>,
	Linux Memory Management List <linux-mm@kvack.org>,
	clang-built-linux <clang-built-linux@googlegroups.com>
Subject: Re: [PATCH 3/6] tracing: Wrap section comparison in tracer_alloc_buffers with COMPARE_SECTIONS
Date: Wed, 19 Feb 2020 14:43:33 -0500	[thread overview]
Message-ID: <20200219144333.1ce3f9ea@gandalf.local.home> (raw)
In-Reply-To: <20200219192249.GA8840@ubuntu-m2-xlarge-x86>

On Wed, 19 Feb 2020 12:22:49 -0700
Nathan Chancellor <natechancellor@gmail.com> wrote:

> Yes, thank you for the analysis and further discussion! I have done some
> rudimentary printk debugging in QEMU and it looks like these are produce
> the same value:
> 
> __stop___trace_bprintk_fmt
> &__stop___trace_bprintk_fmt
> &__start___trace_bprintk_fmt[0]
> 
> as well as
> 
> __stop___trace_bprintk_fmt != __start___trace_bprintk_fmt
> &__stop___trace_bprintk_fmt != &__start___trace_bprintk_fmt
> &__stop___trace_bprintk_fmt[0] != &__start___trace_bprintk_fmt[0]
> 
> I'll use the second one once I confirm this is true in all callspots
> with both Clang and GCC, since it looks cleaner. Let me know if there
> are any objections to that.

Myself and I'm sure others would be fine with this approach as it is
still readable. I was just against the encapsulating the logic in a
strange macro that killed readability.

I haven't looked at the resulting assembly from these, and will
currently take your word for it ;-)  Of course, I will thoroughly test
any patches to this code to make sure it does not hurt functionality.

-- Steve


  reply	other threads:[~2020-02-19 19:43 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-19  4:54 [PATCH 0/6] Silence some instances of -Wtautological-compare and enable globally Nathan Chancellor
2020-02-19  4:54 ` [PATCH 1/6] asm/sections: Add COMPARE_SECTIONS macro Nathan Chancellor
2020-02-19  4:54 ` [PATCH 2/6] kernel/extable: Wrap section comparison in sort_main_extable with COMPARE_SECTIONS Nathan Chancellor
2020-02-19  4:54 ` [PATCH 3/6] tracing: Wrap section comparison in tracer_alloc_buffers " Nathan Chancellor
2020-02-19 14:34   ` Steven Rostedt
2020-02-19 17:44     ` Nick Desaulniers
2020-02-19 18:16       ` Jason Gunthorpe
2020-02-19 19:09         ` Steven Rostedt
2020-02-19 19:11         ` Nick Desaulniers
2020-02-19 19:22           ` Nathan Chancellor
2020-02-19 19:43             ` Steven Rostedt [this message]
2020-02-19 19:54           ` Jason Gunthorpe
2020-02-19 21:32             ` Nick Desaulniers
2020-02-19  4:54 ` [PATCH 4/6] dynamic_debug: Wrap section comparison in dynamic_debug_init " Nathan Chancellor
2020-02-19  4:54 ` [PATCH 5/6] mm: kmemleak: Wrap section comparison in kmemleak_init " Nathan Chancellor
2020-02-19  4:54 ` [PATCH 6/6] kbuild: Enable -Wtautological-compare Nathan Chancellor
2020-04-21  4:03 ` [PATCH 0/6] Silence some instances of -Wtautological-compare and enable globally Andrew Morton
2020-04-21  4:32   ` Nathan Chancellor

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=20200219144333.1ce3f9ea@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=catalin.marinas@arm.com \
    --cc=clang-built-linux@googlegroups.com \
    --cc=jbaron@akamai.com \
    --cc=jgg@ziepe.ca \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=masahiroy@kernel.org \
    --cc=michal.lkml@markovi.net \
    --cc=mingo@redhat.com \
    --cc=natechancellor@gmail.com \
    --cc=ndesaulniers@google.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).