From c0999a5d0212fc3440606a76d3f716655dc05840 Mon Sep 17 00:00:00 2001 From: mpolacek Date: Fri, 2 Oct 2015 17:49:15 +0000 Subject: [PATCH] * genemit.c (gen_exp): Remove -Wduplicated-cond hack. * c.opt (Wduplicated-cond): Don't enable by -Wall anymore. * c-c++-common/Wduplicated-cond-2.c: Skip until PR67819 is resolved. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@228405 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 4 ++++ gcc/c-family/ChangeLog | 4 ++++ gcc/c-family/c.opt | 2 +- gcc/genemit.c | 2 +- gcc/testsuite/ChangeLog | 4 ++++ gcc/testsuite/c-c++-common/Wduplicated-cond-2.c | 1 + 6 files changed, 15 insertions(+), 2 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f9e5372..6e41810 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2015-10-02 Marek Polacek + + * genemit.c (gen_exp): Remove -Wduplicated-cond hack. + 2015-10-02 Aditya Kumar * graphite-scop-detection.c (loop_ivs_can_be_represented): New. diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog index 8ab8964..78cc2bd 100644 --- a/gcc/c-family/ChangeLog +++ b/gcc/c-family/ChangeLog @@ -1,5 +1,9 @@ 2015-10-02 Marek Polacek + * c.opt (Wduplicated-cond): Don't enable by -Wall anymore. + +2015-10-02 Marek Polacek + PR c/64249 * c-common.c (warn_duplicated_cond_add_or_warn): New function. * c-common.h (warn_duplicated_cond_add_or_warn): Declare. diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt index a79b9f1..c62eefb 100644 --- a/gcc/c-family/c.opt +++ b/gcc/c-family/c.opt @@ -407,7 +407,7 @@ C ObjC C++ ObjC++ Var(warn_div_by_zero) Init(1) Warning Warn about compile-time integer division by zero Wduplicated-cond -C ObjC C++ ObjC++ Var(warn_duplicated_cond) Warning LangEnabledBy(C ObjC C++ ObjC++,Wall) +C ObjC C++ ObjC++ Var(warn_duplicated_cond) Init(0) Warning Warn about duplicated conditions in an if-else-if chain Weffc++ diff --git a/gcc/genemit.c b/gcc/genemit.c index 13f9119..e92f757 100644 --- a/gcc/genemit.c +++ b/gcc/genemit.c @@ -182,7 +182,7 @@ gen_exp (rtx x, enum rtx_code subroutine_type, char *used) && INTVAL (x) <= MAX_SAVED_CONST_INT) printf ("const_int_rtx[MAX_SAVED_CONST_INT + (%d)]", (int) INTVAL (x)); - else if (STORE_FLAG_VALUE > 1 && INTVAL (x) == STORE_FLAG_VALUE) + else if (INTVAL (x) == STORE_FLAG_VALUE) printf ("const_true_rtx"); else { diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 58a0289..8211e03 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2015-10-02 Marek Polacek + + * c-c++-common/Wduplicated-cond-2.c: Skip until PR67819 is resolved. + 2015-10-02 Sebastian Pop PR tree-optimization/67754 diff --git a/gcc/testsuite/c-c++-common/Wduplicated-cond-2.c b/gcc/testsuite/c-c++-common/Wduplicated-cond-2.c index 90a8663..c424e76 100644 --- a/gcc/testsuite/c-c++-common/Wduplicated-cond-2.c +++ b/gcc/testsuite/c-c++-common/Wduplicated-cond-2.c @@ -1,6 +1,7 @@ /* PR c/64249 */ /* { dg-do compile } */ /* { dg-options "-Wall" } */ +/* { dg-skip-if "PR67819" { *-*-* } } */ #ifndef __cplusplus # define bool _Bool -- 2.7.4