diff options
author | Jakub Jelinek <jakub@redhat.com> | 2016-04-26 08:10:43 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2016-04-26 08:10:43 +0200 |
commit | 7db11a5a3233b5181d38957a426f88da1d791478 (patch) | |
tree | 3ae8d8abe5093326ad45e3a9961718c34e91ccd9 /gcc | |
parent | 513d5d7f553f880388845950cd771edda6e769fd (diff) | |
download | gcc-7db11a5a3233b5181d38957a426f88da1d791478.zip gcc-7db11a5a3233b5181d38957a426f88da1d791478.tar.gz gcc-7db11a5a3233b5181d38957a426f88da1d791478.tar.bz2 |
re PR bootstrap/70704 (AIX bootstrap comparison failure)
PR bootstrap/70704
* configure.ac (--enable-stage1-checking): For --disable-checking or
implicit --enable-checking, make sure extra flag matches in between
stage1 and later checking.
* configure: Regenerated.
gcc/
* configure.ac (--enable-checking): Document extra flag, for
non-release builds default to --enable-checking=yes,extra.
If misc checking and extra checking, define CHECKING_P to 2 instead
of 1.
* common.opt (fchecking=): Add.
* doc/invoke.texi (-fchecking=): Document.
* doc/install.texi: Document --enable-checking changes.
* configure: Regenerated.
* config.in: Regenerated.
gcc/cp/
* pt.c (build_non_dependent_expr): Use flag_checking > 1 instead of
just flag_checking.
From-SVN: r235430
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 13 | ||||
-rw-r--r-- | gcc/common.opt | 4 | ||||
-rw-r--r-- | gcc/config.in | 3 | ||||
-rwxr-xr-x | gcc/configure | 26 | ||||
-rw-r--r-- | gcc/configure.ac | 23 | ||||
-rw-r--r-- | gcc/cp/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/cp/pt.c | 6 | ||||
-rw-r--r-- | gcc/doc/install.texi | 9 | ||||
-rw-r--r-- | gcc/doc/invoke.texi | 7 |
9 files changed, 70 insertions, 27 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 282642c..21ac472 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,16 @@ +2016-04-26 Jakub Jelinek <jakub@redhat.com> + + PR bootstrap/70704 + * configure.ac (--enable-checking): Document extra flag, for + non-release builds default to --enable-checking=yes,extra. + If misc checking and extra checking, define CHECKING_P to 2 instead + of 1. + * common.opt (fchecking=): Add. + * doc/invoke.texi (-fchecking=): Document. + * doc/install.texi: Document --enable-checking changes. + * configure: Regenerated. + * config.in: Regenerated. + 2016-04-25 Uros Bizjak <ubizjak@gmail.com> * config/i386/i386.md (*movxi_internal_avx512f): Use insn type diff --git a/gcc/common.opt b/gcc/common.opt index 67048db..682cb41 100644 --- a/gcc/common.opt +++ b/gcc/common.opt @@ -1029,6 +1029,10 @@ fchecking Common Var(flag_checking) Init(CHECKING_P) Perform internal consistency checkings. +fchecking= +Common Joined RejectNegative UInteger Var(flag_checking) +Perform internal consistency checkings. + fcombine-stack-adjustments Common Report Var(flag_combine_stack_adjustments) Optimization Looks for opportunities to reduce stack adjustments and stack references. diff --git a/gcc/config.in b/gcc/config.in index 115cb61..bdde25f 100644 --- a/gcc/config.in +++ b/gcc/config.in @@ -31,7 +31,8 @@ /* Define to 1 if you want more run-time sanity checks. This one gets a grab - bag of miscellaneous but relatively cheap checks. */ + bag of miscellaneous but relatively cheap checks. Define to 2 if you want + also extra run-time checking that might affect code generation. */ #ifndef USED_FOR_TARGET #undef CHECKING_P #endif diff --git a/gcc/configure b/gcc/configure index 1c6e340..d4d5ddf 100755 --- a/gcc/configure +++ b/gcc/configure @@ -1596,7 +1596,7 @@ Optional Features: enable expensive run-time checks. With LIST, enable only specific categories of checks. Categories are: yes,no,all,none,release. Flags are: - assert,df,fold,gc,gcac,gimple,misc, + assert,df,extra,fold,gc,gcac,gimple,misc, rtlflag,rtl,runtime,tree,valgrind,types --enable-coverage[=LEVEL] enable compiler's code coverage collection. Use to @@ -7075,7 +7075,7 @@ else # Determine the default checks. if test x$is_release = x ; then - ac_checking_flags=yes + ac_checking_flags=yes,extra else ac_checking_flags=release fi @@ -7087,32 +7087,33 @@ do case $check in # these set all the flags to specific states yes) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking= ; - ac_fold_checking= ; ac_gc_checking=1 ; + ac_fold_checking= ; ac_gc_checking=1 ; ac_extra_checking= ; ac_gc_always_collect= ; ac_gimple_checking=1 ; ac_rtl_checking= ; ac_rtlflag_checking=1 ; ac_runtime_checking=1 ; ac_tree_checking=1 ; ac_valgrind_checking= ; ac_types_checking=1 ;; no|none) ac_assert_checking= ; ac_checking= ; ac_df_checking= ; - ac_fold_checking= ; ac_gc_checking= ; + ac_fold_checking= ; ac_gc_checking= ; ac_extra_checking= ; ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ; ac_rtlflag_checking= ; ac_runtime_checking= ; ac_tree_checking= ; ac_valgrind_checking= ; ac_types_checking= ;; all) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking=1 ; - ac_fold_checking=1 ; ac_gc_checking=1 ; + ac_fold_checking=1 ; ac_gc_checking=1 ; ac_extra_checking=1 ; ac_gc_always_collect=1 ; ac_gimple_checking=1 ; ac_rtl_checking=1 ; ac_rtlflag_checking=1 ; ac_runtime_checking=1 ; ac_tree_checking=1 ; ac_valgrind_checking= ; ac_types_checking=1 ;; release) ac_assert_checking=1 ; ac_checking= ; ac_df_checking= ; - ac_fold_checking= ; ac_gc_checking= ; + ac_fold_checking= ; ac_gc_checking= ; ac_extra_checking= ; ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ; ac_rtlflag_checking= ; ac_runtime_checking=1 ; ac_tree_checking= ; ac_valgrind_checking= ; ac_types_checking= ;; # these enable particular checks assert) ac_assert_checking=1 ;; - df) ac_df_checking=1 ;; + df) ac_df_checking=1 ;; + extra) ac_extra_checking=1 ;; fold) ac_fold_checking=1 ;; gc) ac_gc_checking=1 ;; gcac) ac_gc_always_collect=1 ;; @@ -7131,8 +7132,13 @@ IFS="$ac_save_IFS" nocommon_flag="" if test x$ac_checking != x ; then + if test x$ac_extra_checking != x ; then + ac_checking=2 + fi -$as_echo "#define CHECKING_P 1" >>confdefs.h +cat >>confdefs.h <<_ACEOF +#define CHECKING_P $ac_checking +_ACEOF nocommon_flag=-fno-common else @@ -18453,7 +18459,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 18456 "configure" +#line 18462 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -18559,7 +18565,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 18562 "configure" +#line 18568 "configure" #include "confdefs.h" #if HAVE_DLFCN_H diff --git a/gcc/configure.ac b/gcc/configure.ac index 6c1dcd9..0328a2c 100644 --- a/gcc/configure.ac +++ b/gcc/configure.ac @@ -516,12 +516,12 @@ AC_ARG_ENABLE(checking, [enable expensive run-time checks. With LIST, enable only specific categories of checks. Categories are: yes,no,all,none,release. - Flags are: assert,df,fold,gc,gcac,gimple,misc, + Flags are: assert,df,extra,fold,gc,gcac,gimple,misc, rtlflag,rtl,runtime,tree,valgrind,types])], [ac_checking_flags="${enableval}"],[ # Determine the default checks. if test x$is_release = x ; then - ac_checking_flags=yes + ac_checking_flags=yes,extra else ac_checking_flags=release fi]) @@ -531,32 +531,33 @@ do case $check in # these set all the flags to specific states yes) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking= ; - ac_fold_checking= ; ac_gc_checking=1 ; + ac_fold_checking= ; ac_gc_checking=1 ; ac_extra_checking= ; ac_gc_always_collect= ; ac_gimple_checking=1 ; ac_rtl_checking= ; ac_rtlflag_checking=1 ; ac_runtime_checking=1 ; ac_tree_checking=1 ; ac_valgrind_checking= ; ac_types_checking=1 ;; no|none) ac_assert_checking= ; ac_checking= ; ac_df_checking= ; - ac_fold_checking= ; ac_gc_checking= ; + ac_fold_checking= ; ac_gc_checking= ; ac_extra_checking= ; ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ; ac_rtlflag_checking= ; ac_runtime_checking= ; ac_tree_checking= ; ac_valgrind_checking= ; ac_types_checking= ;; all) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking=1 ; - ac_fold_checking=1 ; ac_gc_checking=1 ; + ac_fold_checking=1 ; ac_gc_checking=1 ; ac_extra_checking=1 ; ac_gc_always_collect=1 ; ac_gimple_checking=1 ; ac_rtl_checking=1 ; ac_rtlflag_checking=1 ; ac_runtime_checking=1 ; ac_tree_checking=1 ; ac_valgrind_checking= ; ac_types_checking=1 ;; release) ac_assert_checking=1 ; ac_checking= ; ac_df_checking= ; - ac_fold_checking= ; ac_gc_checking= ; + ac_fold_checking= ; ac_gc_checking= ; ac_extra_checking= ; ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ; ac_rtlflag_checking= ; ac_runtime_checking=1 ; ac_tree_checking= ; ac_valgrind_checking= ; ac_types_checking= ;; # these enable particular checks assert) ac_assert_checking=1 ;; - df) ac_df_checking=1 ;; + df) ac_df_checking=1 ;; + extra) ac_extra_checking=1 ;; fold) ac_fold_checking=1 ;; gc) ac_gc_checking=1 ;; gcac) ac_gc_always_collect=1 ;; @@ -575,9 +576,13 @@ IFS="$ac_save_IFS" nocommon_flag="" if test x$ac_checking != x ; then - AC_DEFINE(CHECKING_P, 1, + if test x$ac_extra_checking != x ; then + ac_checking=2 + fi + AC_DEFINE_UNQUOTED(CHECKING_P, $ac_checking, [Define to 1 if you want more run-time sanity checks. This one gets a grab - bag of miscellaneous but relatively cheap checks.]) + bag of miscellaneous but relatively cheap checks. Define to 2 if you want + also extra run-time checking that might affect code generation.]) nocommon_flag=-fno-common else AC_DEFINE(CHECKING_P, 0) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index e9c50d6..a81ffa0 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,9 @@ +2016-04-26 Jakub Jelinek <jakub@redhat.com> + + PR bootstrap/70704 + * pt.c (build_non_dependent_expr): Use flag_checking > 1 instead of + just flag_checking. + 2016-04-25 Jason Merrill <jason@redhat.com> * tree.c (std_attribute_table): New. diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index e18422f..2d033e3 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -23623,8 +23623,10 @@ build_non_dependent_expr (tree expr) /* When checking, try to get a constant value for all non-dependent expressions in order to expose bugs in *_dependent_expression_p - and constexpr. */ - if (flag_checking && cxx_dialect >= cxx11 + and constexpr. This can affect code generation, see PR70704, so + only do this for -fchecking=2. */ + if (flag_checking > 1 + && cxx_dialect >= cxx11 /* Don't do this during nsdmi parsing as it can lead to unexpected recursive instantiations. */ && !parsing_nsdmi ()) diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi index 4268036..e1ca26c 100644 --- a/gcc/doc/install.texi +++ b/gcc/doc/install.texi @@ -1708,7 +1708,7 @@ When you specify this option, the compiler is built to perform internal consistency checks of the requested complexity. This does not change the generated code, but adds error checking within the compiler. This will slow down the compiler and may only work properly if you are building -the compiler with GCC@. This is @samp{yes} by default when building +the compiler with GCC@. This is @samp{yes,extra} by default when building from SVN or snapshots, but @samp{release} for releases. The default for building the stage1 compiler is @samp{yes}. More control over the checks may be had by specifying @var{list}. The categories of @@ -1717,8 +1717,11 @@ checks available are @samp{yes} (most common checks all), @samp{all} (all but @samp{valgrind}), @samp{release} (cheapest checks @samp{assert,runtime}) or @samp{none} (same as @samp{no}). Individual checks can be enabled with these flags @samp{assert}, -@samp{df}, @samp{fold}, @samp{gc}, @samp{gcac} @samp{misc}, @samp{rtl}, -@samp{rtlflag}, @samp{runtime}, @samp{tree}, and @samp{valgrind}. +@samp{df}, @samp{fold}, @samp{gc}, @samp{gcac}, @samp{misc}, @samp{rtl}, +@samp{rtlflag}, @samp{runtime}, @samp{tree}, @samp{extra} and @samp{valgrind}. +@samp{extra} adds for @samp{misc} checking extra checks that might affect +code generation and should therefore not differ between stage1 and later +stages. The @samp{valgrind} check requires the external @command{valgrind} simulator, available from @uref{http://valgrind.org/}. The diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 821f8fd..0f97e6d 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -501,7 +501,8 @@ Objective-C and Objective-C++ Dialects}. @item Developer Options @xref{Developer Options,,GCC Developer Options}. @gccoptlist{-d@var{letters} -dumpspecs -dumpmachine -dumpversion @gol --fchecking -fdbg-cnt-list -fdbg-cnt=@var{counter-value-list} @gol +-fchecking -fchecking=@var{n} -fdbg-cnt-list @gol +-fdbg-cnt=@var{counter-value-list} @gol -fdisable-ipa-@var{pass_name} @gol -fdisable-rtl-@var{pass_name} @gol -fdisable-rtl-@var{pass-name}=@var{range-list} @gol @@ -12368,10 +12369,12 @@ Here are some examples showing uses of these options. @end smallexample @item -fchecking +@itemx -fchecking=@var{n} @opindex fchecking @opindex fno-checking Enable internal consistency checking. The default depends on -the compiler configuration. +the compiler configuration. @option{-fchecking=2} enables further +internal consistency checking that might affect code generation. @item -frandom-seed=@var{string} @opindex frandom-seed |