public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely.gcc@gmail.com>
To: Tom Kacvinsky <tkacvins@gmail.com>
Cc: gcc-help@gnu.org
Subject: Re: GCC 12.1, -isystem, -Wsystem-headers, and -Wmaybe-uninitialized
Date: Wed, 18 May 2022 19:32:13 +0100	[thread overview]
Message-ID: <CAH6eHdQLJR57YgJY=bcE7MYekJJkBUx356NYuDOQQsjYEMmxBw@mail.gmail.com> (raw)
In-Reply-To: <CAG_eJLdCbKdDoN8k4zCeVtoOF+Tt=5YP6+xsRQCsM=pkMT35CQ@mail.gmail.com>

On Wed, 18 May 2022, 17:57 Tom Kacvinsky via Gcc-help, <gcc-help@gcc.gnu.org>
wrote:

> We were happily using -Wall -Wextra -Werror with GCC 8.3.0 and -isystem
> for Boost header files to squelch any warnings that would come out of
> Boost.
>
> I recently switched to GCC 12.1 and now we are getting
> -Wmaybe-uninitialized errors out of Boost.  So I am not sure if
> -Wsystem-headers was not part of -Wall -Wextra in GCC 8.3.0 but is now
> part of GCC 12.1.0.
>

No it isn't, it's just that some warnings are now given even if they occur
in system headers.



> Optimization level plays a role in this.  With -O0 (GCC 12.1), the
> warning does not happen, but with -O3, it does.
>

The uninitialised warnings depend on data flow analysis, which only happens
with optimization.



> So I am not sure of the interaction between optimization, -Wall -Wextra,
> -Wsystem-headers, and GCC 8.3.0 and GCC 12.1.0.
>
> Any ideas?
>
> Thanks, Tom
>

      reply	other threads:[~2022-05-18 18:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-18 16:56 Tom Kacvinsky
2022-05-18 18:32 ` Jonathan Wakely [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='CAH6eHdQLJR57YgJY=bcE7MYekJJkBUx356NYuDOQQsjYEMmxBw@mail.gmail.com' \
    --to=jwakely.gcc@gmail.com \
    --cc=gcc-help@gnu.org \
    --cc=tkacvins@gmail.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).