This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch, fortran] RFD: PR 56666 Allow suppression of zero-trip DO loop warning
- From: Janus Weil <janus at gcc dot gnu dot org>
- To: Thomas Koenig <tkoenig at netcologne dot de>
- Cc: "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 12 Aug 2013 00:48:51 +0200
- Subject: Re: [patch, fortran] RFD: PR 56666 Allow suppression of zero-trip DO loop warning
- References: <51FD2FA9 dot 508 at netcologne dot de> <CAKwh3qgx3LAO08hW9LXMXyU=6BsbzkBkvoAcYnEKomuy3b8WKg at mail dot gmail dot com> <52080744 dot 2070609 at netcologne dot de>
2013/8/11 Thomas Koenig <tkoenig@netcologne.de>:
> Hi Janus,
>
>> So: Ok for trunk from my side.
>>
>> However, I would prefer to disable the warning by default, but include
>> it in -Wall.
>
> Here's a patch to do just that.
>
> Regression-tested (hence the changes to the existing test cases :-)
>
> OK for trunk?
Looks good to me ...
Thanks,
Janus
> 2013-08-03 Thomas Koenig <tkoenig@gcc.gnu.org>
>
> PR fortran/56666
> * gfortran.h (gfc_option_t): Add warn_zerotrip.
> * invoke.texi (-Wzerotrip): Document option.
> * lang.opt (Wzerotrip): Add.
> * options.c (gfc_init_options): Initialize warn_zerotrip.
> (set_Wall): Add handling of warn_zerotrip.
> (gfc_handle_option): Handle OPT_Wzerotrip.
> * resolve.c (gfc_resolve_iterator): Honor
> gfc_option.warn_zerotrip; update error message to show
> how to suppress the warning.
>
> 2013-08-03 Thomas Koenig <tkoenig@gcc.gnu.org>
>
> PR fortran/56666
> * gfortran.dg/do_check_10.f90: New test.
> * gfortran.dg/array_constructor_11.f90: Add -Wzerotrip to
> dg-options.
> * gfortran.dg/array_constructor_18.f90: Likewise.
> * gfortran.dg/array_constructor_22.f90: Likewise.
> * gfortran.dg/coarray_15.f90: Likewise.
> * gfortran.dg/do_1.f90: Add -Wall to dg-options.
> * gfortran.dg/do_3.F90: Add -Wzerotrip to dg-options.
> * gfortran.dg/do_check_5.f90: Add -Wall to gd-options.
>