public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Florian Weimer <fweimer@redhat.com>
To: Martin Sebor via Libc-alpha <libc-alpha@sourceware.org>
Subject: Re: [RFC patch] avoid warning on accesses to hardwired address
Date: Wed, 21 Jul 2021 15:06:25 +0200	[thread overview]
Message-ID: <87lf5zn7e6.fsf@oldenburg.str.redhat.com> (raw)
In-Reply-To: <87sg0oj8q7.fsf@oldenburg.str.redhat.com> (Florian Weimer's message of "Fri, 09 Jul 2021 08:34:56 +0200")

* Florian Weimer:

> * Martin Sebor via Libc-alpha:
>
>> Thanks to recent code refactoring in GCC 12, -Warray-bounds has
>> started to diagnose accesses to constant addresses just like many
>> other flow based warnings do (e.g., -Wstringop-overflow).
>> The warnings are meant to help detect accesses resulting from
>> invalid arithmetic on null pointers.  There may be a better way
>> to detect them but GCC doesn't have the detection yet.  This
>> warning change has in turn exposed Glibc's uses of this trick
>> in the implementation of the THREAD_SELF macro.
>
> The warning needs to be disabled in GCC for named address spaces.  Null
> pointers are not special for them.

Is there already a GCC PR for this warning regression?

Thanks,
Florian


  reply	other threads:[~2021-07-21 13:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-09  0:55 Martin Sebor
2021-07-09  6:34 ` Florian Weimer
2021-07-21 13:06   ` Florian Weimer [this message]
2021-07-21 16:17     ` Martin Sebor
2021-08-16 11:27 ` Martin Liška
2021-08-16 15:24   ` Martin Sebor

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=87lf5zn7e6.fsf@oldenburg.str.redhat.com \
    --to=fweimer@redhat.com \
    --cc=libc-alpha@sourceware.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 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 read-only IMAP folder(s) and NNTP newsgroup(s).