From: Richard Biener <rguenther@suse.de>
To: Jeff Law <law@redhat.com>
Cc: Martin Sebor <msebor@gmail.com>,
gcc-patches@gcc.gnu.org,
Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
Subject: Re: Fix PR78154
Date: Thu, 17 Nov 2016 08:48:00 -0000 [thread overview]
Message-ID: <alpine.LSU.2.11.1611170948020.5294@t29.fhfr.qr> (raw)
In-Reply-To: <15ea31ce-87c8-012c-e8d6-d3f0bb3d31dd@redhat.com>
On Wed, 16 Nov 2016, Jeff Law wrote:
> On 11/16/2016 05:17 PM, Martin Sebor wrote:
>
> > >
> > > (I've heard some noise in C++-land about making memcpy(0,0,0) valid, but
> > > that may have just been noise)
> >
> > We may have read the same discussion. It would make some things
> > a little easier in C++ (and remove what most people view as yet
> > another unnecessary gotcha in the language).
> And that may be a reasonable thing to do.
>
> While GCC does take advantage of the non-null attribute when trying to prove
> certain pointers must be non-null, it only does so when the magic flag is
> turned on. There was a sense that it was too aggressive and that time may be
> necessary for folks to come to terms with what GCC was doing, particularly in
> the the memcpy (*, *, 0) case -- but I've never gotten the sense that happened
> and we've never turned that flag on by default.
We only have -f[no-]delete-null-pointer-checks and that's on by default.
So we _do_ take advantage of those.
Richard.
next prev parent reply other threads:[~2016-11-17 8:48 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-16 18:49 Prathamesh Kulkarni
2016-11-16 18:55 ` Jakub Jelinek
2016-11-16 20:27 ` Martin Sebor
2016-11-16 21:21 ` Marc Glisse
2016-11-17 0:17 ` Martin Sebor
2016-11-17 0:39 ` Martin Sebor
2016-11-17 4:57 ` Jeff Law
2016-11-17 8:48 ` Richard Biener [this message]
2016-11-17 15:19 ` Jeff Law
2016-11-17 8:51 ` Richard Biener
2016-11-17 9:34 ` Prathamesh Kulkarni
2016-11-17 9:54 ` Richard Biener
2016-11-18 13:03 ` Prathamesh Kulkarni
2016-11-21 10:04 ` Richard Biener
2016-11-22 10:14 ` Prathamesh Kulkarni
2016-11-22 14:53 ` Richard Biener
2016-11-23 9:35 ` Prathamesh Kulkarni
2016-11-23 9:42 ` Richard Biener
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=alpine.LSU.2.11.1611170948020.5294@t29.fhfr.qr \
--to=rguenther@suse.de \
--cc=gcc-patches@gcc.gnu.org \
--cc=law@redhat.com \
--cc=msebor@gmail.com \
--cc=prathamesh.kulkarni@linaro.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).