public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <law@redhat.com>
To: Chung-Lin Tang <cltang@codesourcery.com>,
	       gcc-patches <gcc-patches@gcc.gnu.org>
Cc: Nathan Sidwell <nathan@codesourcery.com>
Subject: Re: [PATCH] Propagate -fdiagnostics-* options in lto-wrapper
Date: Wed, 09 Sep 2015 21:40:00 -0000	[thread overview]
Message-ID: <55F0A543.6030306@redhat.com> (raw)
In-Reply-To: <55EC0E15.3080008@codesourcery.com>

On 09/06/2015 03:57 AM, Chung-Lin Tang wrote:
> Hi,
> Currently most non-target specific options are skipped when crossing the
> LTO/offload processing border, however since there are still quite a
> number of warning calls in many target backends, it makes sense to
> save and propagate the associated options, to preserve consistency in warning
> behavior.
>
> For example, currently:
> $ x86_64-pc-linux-gnu-gcc -fopenacc test.c -fno-diagnostics-show-caret
> y.c: In function 'main._omp_fn.0':
> y.c:6:11: warning: using num_workers (32), ignoring 500
>     #pragma acc parallel num_workers(500)
>             ^
> (note: this warning message is triggered by nvptx code currently only
> on gomp-4_0-branch, but illustrates the point)
>
> The caret stills shows, because -fno-diagnostics-show-caret does not
> reach the accel compiler. -flto should also have a similar issue.
>
> The attached patch allows a series of -fdiagnostics-* options to be
> propagated by lto-wrapper.  I've tested this patch without regressions,
> is this okay for trunk?
>
> Thanks,
> Chung-Lin
>
> 2015-09-06  Chung-Lin Tang  <cltang@codesourcery.com>
>
> 	* lto-wrapper.c (merge_and_complain): Add OPT_fdiagnostics_show_caret,
> 	OPT_fdiagnostics_show_option, OPT_fdiagnostics_show_location_, and
> 	OPT_fshow_column to handled saved option cases.
> 	(append_compiler_options): Do not skip the above added options.
OK.  Please install.

Thanks,
Jeff

      reply	other threads:[~2015-09-09 21:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-06 11:42 Chung-Lin Tang
2015-09-09 21:40 ` Jeff Law [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=55F0A543.6030306@redhat.com \
    --to=law@redhat.com \
    --cc=cltang@codesourcery.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=nathan@codesourcery.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).