From: "H.J. Lu" <hjl.tools@gmail.com>
To: "Simon Baldwin" <simonb@google.com>
Cc: "Mark Mitchell" <mark@codesourcery.com>,
gcc-patches@gcc.gnu.org,
"Richard Guenther" <richard.guenther@gmail.com>,
"Dirk Mueller" <dmuell@gmx.net>,
"Joseph S. Myers" <joseph@codesourcery.com>
Subject: Re: [PATCH][RFC] Add a subset of -Warray-bounds warnings to C/C++ front ends
Date: Fri, 02 May 2008 12:58:00 -0000 [thread overview]
Message-ID: <6dc9ffc80805020557w60e00df6p9f38f65824d4b29c@mail.gmail.com> (raw)
In-Reply-To: <6dc9ffc80805020550r7718ec8l11a11f4d1d779a8b@mail.gmail.com>
Hi Simon,
In http://gcc.gnu.org/ml/gcc-patches/2008-04/msg01945.html, you said
---
A side effect of copying these warnings up into the language frontends is
that warnings are now printed even if the array access is in dead or
inaccessible code.
---
So this behavior is intentional. I don't see how it will be useful. Should
this patch be reverted for now?
Thanks.
H.J.
---
On Fri, May 2, 2008 at 5:50 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
> Hi Simon,
>
> Your patch breaks gcc bootstrap:
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36108
>
>
> H.J.
>
>
> On Thu, May 1, 2008 at 12:07 PM, Simon Baldwin <simonb@google.com> wrote:
> > Thanks all. Committed, with suggested doc/invoke.texi change, as revision
> > 134865.
> >
> >
> >
> >
> > Mark Mitchell wrote:
> >
> > > Simon Baldwin wrote:
> > >
> > > > Thanks to a well targeted pointer from Tom Tromey, I've now added the
> > extra logic to suppress warnings about "sizeof(a[-1])" in the C and C++
> > frontends. Attached is the revised version.
> > > >
> > >
> > > Thanks for following up. I think this is a worthwhile patch.
> > >
> > >
> > > > +This option performs a subset of checks in unoptimized compilations,
> > and
> > > > +stricter checking when @option{-ftree-vrp} is active
> > > > (default for -O2 and above).
> > > >
> > >
> > > I think "stricter" could be made more explicit. How about something like:
> > >
> > > This option detects some cases of out-of-bounds accesses in unoptimized
> > compilations. More cases are detected when @option{-ftree-vrp} is enabled.
> > (The @option{-ftree-vrp} option is enabled automatically when compiling with
> > @option{-O2} or higher optimization options.)
> > >
> > > Joseph, do you have any comments on the C changes? Simon, if you do not
> > hear otherwise from Joseph within 72 hours, this patch is OK.
> > >
> > > Thanks,
> > >
> > >
> >
> >
>
next prev parent reply other threads:[~2008-05-02 12:58 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-04 1:04 Simon Baldwin
2008-04-04 9:59 ` Richard Guenther
2008-04-04 23:50 ` Simon Baldwin
2008-04-05 0:50 ` Andrew Pinski
2008-04-07 22:51 ` Simon Baldwin
2008-04-08 9:43 ` Richard Guenther
2008-04-08 15:39 ` Dirk Mueller
2008-04-08 15:21 ` Dirk Mueller
2008-04-10 18:05 ` Andrew Pinski
2008-04-08 19:42 ` Mark Mitchell
2008-04-11 20:37 ` Simon Baldwin
2008-04-15 19:18 ` Tom Tromey
2008-04-26 13:42 ` Simon Baldwin
2008-04-27 14:56 ` Mark Mitchell
2008-04-27 15:05 ` Joseph S. Myers
2008-05-01 19:07 ` Simon Baldwin
2008-05-02 12:51 ` H.J. Lu
2008-05-02 12:58 ` H.J. Lu [this message]
2008-05-02 14:06 ` Mark Mitchell
2008-05-02 16:04 ` H.J. Lu
2008-05-02 16:21 ` Simon Baldwin
2008-05-02 16:35 ` Mark Mitchell
2008-05-02 19:53 ` Andrew Pinski
2008-05-02 20:01 ` H.J. Lu
2008-05-02 20:04 ` Simon Baldwin
2008-05-02 20:11 ` H.J. Lu
2008-05-02 16:24 ` Paul Koning
2008-04-08 16:07 ` Dirk Mueller
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=6dc9ffc80805020557w60e00df6p9f38f65824d4b29c@mail.gmail.com \
--to=hjl.tools@gmail.com \
--cc=dmuell@gmx.net \
--cc=gcc-patches@gcc.gnu.org \
--cc=joseph@codesourcery.com \
--cc=mark@codesourcery.com \
--cc=richard.guenther@gmail.com \
--cc=simonb@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 read-only IMAP folder(s) and NNTP newsgroup(s).