From: Nathan Chancellor <natechancellor@gmail.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org,
clang-built-linux@googlegroups.com,
Nick Desaulniers <ndesaulniers@google.com>
Subject: Re: [PATCH v2] mm: kmemleak: Use address-of operator on section symbols
Date: Thu, 20 Feb 2020 18:37:56 -0700 [thread overview]
Message-ID: <20200221013756.GA8323@ubuntu-m2-xlarge-x86> (raw)
In-Reply-To: <20200220173501.0de88326911e41b15e27b62f@linux-foundation.org>
On Thu, Feb 20, 2020 at 05:35:01PM -0800, Andrew Morton wrote:
> On Wed, 19 Feb 2020 22:15:51 -0700 Nathan Chancellor <natechancellor@gmail.com> wrote:
>
> > Clang warns:
> >
> > These are not true arrays, they are linker defined symbols, which are
> > just addresses. Using the address of operator silences the warning and
> > does not change the resulting assembly with either clang/ld.lld or
> > gcc/ld (tested with diff + objdump -Dr).
>
> I guess you forgot to quote the clang output?
Ugh yes, sorry. I can send a v3 later or here it is if you want to
stitch it in:
../mm/kmemleak.c:1955:28: warning: array comparison always evaluates to a constant [-Wtautological-compare]
if (__start_ro_after_init < _sdata || __end_ro_after_init > _edata)
^
../mm/kmemleak.c:1955:60: warning: array comparison always evaluates to a constant [-Wtautological-compare]
if (__start_ro_after_init < _sdata || __end_ro_after_init > _edata)
^
2 warnings generated.
Cheers,
Nathan
prev parent reply other threads:[~2020-02-21 1:38 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-20 5:15 Nathan Chancellor
2020-02-20 11:05 ` Catalin Marinas
2020-02-21 1:35 ` Andrew Morton
2020-02-21 1:37 ` Nathan Chancellor [this message]
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=20200221013756.GA8323@ubuntu-m2-xlarge-x86 \
--to=natechancellor@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=catalin.marinas@arm.com \
--cc=clang-built-linux@googlegroups.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--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