aboutsummaryrefslogtreecommitdiff
path: root/gcc
AgeCommit message (Collapse)AuthorFilesLines
2016-10-16re PR ada/37139 (DEP prevents using Ada tasking)Eric Botcazou31-50/+603
PR ada/37139 PR ada/67205 * common.opt (-ftrampolines): New option. * doc/invoke.texi (Code Gen Options): Document it. * doc/tm.texi.in (Trampolines): Add TARGET_CUSTOM_FUNCTION_DESCRIPTORS. * doc/tm.texi: Regenerate. * builtins.def: Add init_descriptor and adjust_descriptor. * builtins.c (expand_builtin_init_trampoline): Do not issue a warning on platforms with descriptors. (expand_builtin_init_descriptor): New function. (expand_builtin_adjust_descriptor): Likewise. (expand_builtin) <BUILT_IN_INIT_DESCRIPTOR>: New case. <BUILT_IN_ADJUST_DESCRIPTOR>: Likewise. * calls.c (prepare_call_address): Remove SIBCALLP parameter and add FLAGS parameter. Deal with indirect calls by descriptor and adjust. Set STATIC_CHAIN_REG_P on the static chain register, if any. (call_expr_flags): Set ECF_BY_DESCRIPTOR for calls by descriptor. (expand_call): Likewise. Move around call to prepare_call_address and pass all flags to it. * cfgexpand.c (expand_call_stmt): Reinstate CALL_EXPR_BY_DESCRIPTOR. * gimple.h (enum gf_mask): New GF_CALL_BY_DESCRIPTOR value. (gimple_call_set_by_descriptor): New setter. (gimple_call_by_descriptor_p): New getter. * gimple.c (gimple_build_call_from_tree): SetCALL_EXPR_BY_DESCRIPTOR. (gimple_call_flags): Deal with GF_CALL_BY_DESCRIPTOR. * langhooks.h (struct lang_hooks): Add custom_function_descriptors. * langhooks-def.h (LANG_HOOKS_CUSTOM_FUNCTION_DESCRIPTORS): Define. (LANG_HOOKS_INITIALIZER): Add LANG_HOOKS_CUSTOM_FUNCTION_DESCRIPTORS. * rtl.h (STATIC_CHAIN_REG_P): New macro. * rtlanal.c (find_first_parameter_load): Skip static chain registers. * target.def (custom_function_descriptors): New POD hook. * tree.h (FUNC_ADDR_BY_DESCRIPTOR): New flag on ADDR_EXPR. (CALL_EXPR_BY_DESCRIPTOR): New flag on CALL_EXPR. * tree-core.h (ECF_BY_DESCRIPTOR): New mask. Document FUNC_ADDR_BY_DESCRIPTOR and CALL_EXPR_BY_DESCRIPTOR. * tree.c (make_node_stat) <tcc_declaration>: Use FUNCTION_ALIGNMENT. (build_common_builtin_nodes): Initialize init_descriptor and adjust_descriptor. * tree-nested.c: Include target.h. (struct nesting_info): Add 'any_descr_created' field. (get_descriptor_type): New function. (lookup_element_for_decl): New function extracted from... (create_field_for_decl): Likewise. (lookup_tramp_for_decl): ...here. Adjust. (lookup_descr_for_decl): New function. (convert_tramp_reference_op): Deal with descriptors. (build_init_call_stmt): New function extracted from... (finalize_nesting_tree_1): ...here. Adjust and deal withdescriptors. * defaults.h (FUNCTION_ALIGNMENT): Define. (TRAMPOLINE_ALIGNMENT): Set to above instead of FUNCTION_BOUNDARY. * config/i386/i386.h (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define. * config/ia64/ia64.h (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Likewise. * config/rs6000/rs6000.h (TARGET_CUSTOM_FUNCTION_DESCRIPTORS):Likewise. * config/sparc/sparc.h (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Likewise. ada/ * gcc-interface/misc.c (LANG_HOOKS_CUSTOM_FUNCTION_DESCRIPTORS):Define. * gcc-interface/trans.c (Attribute_to_gnu) <Attr_Access>: Deal with a zero TARGET_CUSTOM_FUNCTION_DESCRIPTORS specially for Code_Address. Otherwise, if TARGET_CUSTOM_FUNCTION_DESCRIPTORS is positive, set FUNC_ADDR_BY_DESCRIPTOR for 'Access/'Unrestricted_Access of nested subprograms if the type can use an internal representation. (call_to_gnu): Likewise, but set CALL_EXPR_BY_DESCRIPTOR on indirect calls if the type can use an internal representation. From-SVN: r241222
2016-10-16sparc.c (sparc_expand_vector_init): Only accept literal constants in ↵Eric Botcazou2-3/+7
CONST_VECTORs. * config/sparc/sparc.c (sparc_expand_vector_init): Only accept literal constants in CONST_VECTORs. From-SVN: r241218
2016-10-16re PR fortran/48298 ([F03] User-Defined Derived-Type IO (DTIO))Jerry DeLisle4-1/+84
2016-10-16 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR fortran/48298 * trans-io.c (transfer_expr): Ignore dtio procedures for inquire with iolength. * gfortran.dg/dtio_16.f90: New test. From-SVN: r241216
2016-10-16system-aix.ads (Always_Compatible_Rep): Change to False.Eric Botcazou17-32/+50
* system-aix.ads (Always_Compatible_Rep): Change to False. * system-aix64.ads (Always_Compatible_Rep): Likewise. * system-hpux-ia64.ads (Always_Compatible_Rep): Likewise. * system-hpux.ads (Always_Compatible_Rep): Likewise. * system-linux-alpha.ads (Always_Compatible_Rep): Likewise. * system-linux-hppa.ads (Always_Compatible_Rep): Likewise. * system-linux-ia64.ads (Always_Compatible_Rep): Likewise. * system-linux-mips.ads (Always_Compatible_Rep): Likewise. * system-linux-mips64el.ads (Always_Compatible_Rep): Likewise. * system-linux-mipsel.ads (Always_Compatible_Rep): Likewise. * system-linux-s390.ads (Always_Compatible_Rep): Likewise. * system-linux-s390x.ads (Always_Compatible_Rep): Likewise. * system-linux-sh4.ads (Always_Compatible_Rep): Likewise. * system-linux-sparc.ads (Always_Compatible_Rep): Likewise. * system-linux-sparcv9.ads (Always_Compatible_Rep): Likewise. * system-rtems.ads (Always_Compatible_Rep): Likewise. From-SVN: r241213
2016-10-16Daily bump.GCC Administrator1-1/+1
From-SVN: r241210
2016-10-15sparc.c (sparc_expand_vec_perm_bmask): Use a scratch register as destination ↵Eric Botcazou6-4/+60
of bmask. * config/sparc/sparc.c (sparc_expand_vec_perm_bmask): Use a scratch register as destination of bmask. (vector_init_bshuffle): Likewise. * config/sparc/sparc.md (vec_perm_constv8qi): Likewise. (bmaskdi_vis): Enable only in 64-bit mode. From-SVN: r241205
2016-10-15PR c++/77945 - constexpr and trivial copyJason Merrill4-1/+45
* constexpr.c (maybe_simplify_trivial_copy): New. (cxx_eval_store_expression): Call it. * call.c (build_over_call): Use unsigned char for trivial copy. From-SVN: r241204
2016-10-15rs6000: Fix shrink-wrap-separate for AIXSegher Boessenkool2-16/+33
All out-of-line register save routines need LR, so we cannot wrap the LR component if there are out-of-line saves. This didn't show up for testing on Linux because none of the tests there use out-of-line FPR saves without also using out-of-line GPR saves, which we did handle. This patch fixes it, and also cleans up code a little. * config/rs6000/rs6000.c (rs6000_get_separate_components): Do not make LR a separately shrink-wrapped component unless savres_strategy contains all of {SAVE,REST}_INLINE_{GPRS,FPRS,VRS}. Do not wrap GPRs unless both {SAVE,REST}_INLINE_GPRS. Do not disallow all wrapping when not both {SAVE,REST}_INLINE_GPRS. From-SVN: r241203
2016-10-15optabs.c (expand_parity): Fix mode mismatch, add final conversion and keep ↵Eric Botcazou5-5/+31
looping on failure. * optabs.c (expand_parity): Fix mode mismatch, add final conversion and keep looping on failure. From-SVN: r241202
2016-10-15re PR fortran/77972 (ICE on broken character continuation with -Wall etc.)Jerry DeLisle4-3/+21
2016-10-15 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR fortran/77972 * scanner.c (gfc_next_char_literal): If nextc is null do not decrement the pointer and call the diagnostics. PR fortran/77972 * gfortran.dg/unexpected_eof_4.f90: New test. From-SVN: r241201
2016-10-15PR 48587 Newunit allocatorJanne Blomqvist1-0/+9
2016-10-15 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/48587 * gfortran.dg/negative_unit2.f90: New testcase. From-SVN: r241200
2016-10-15PR 48587 Newunit allocatorJanne Blomqvist1-0/+5
Currently GFortran newer reuses unit numbers allocated with NEWUNIT=, instead having a simple counter that is decremented each time such a unit is opened. For a long running program which repeatedly opens files with NEWUNIT= and closes them, the counter can wrap around and cause an abort. This patch replaces the counter with an allocator that keeps track of which units numbers are allocated, and can reuse them once they have been deallocated. Since operating systems tend to limit the number of simultaneous open files for a process to a relatively modest number, a relatively simple approach with a linear scan through an array suffices. Though as a small optimization there is a low water indicator keeping track of the index for which all unit numbers below are already allocated. This linear scan also ensures that we always allocate the smallest available unit number. 2016-10-15 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/48587 * io/io.h (get_unique_unit_number): Remove prototype. (newunit_alloc): New prototype. * io/open.c (st_open): Call newunit_alloc. * io/unit.c (newunits,newunit_size,newunit_lwi): New static variables. (GFC_FIRST_NEWUNIT): Rename to NEWUNIT_START. (next_available_newunit): Remove variable. (get_unit): Call newunit_alloc, don't try to create negative external unit. (close_unit_1): Call newunit_free. (close_units): Free newunits array. (get_unique_number): Remove function. (newunit_alloc): New function. (newunit_free): New function. * io/transfer.c (data_transfer_init): Check for invalid unit number. testsuite ChangeLog: 2016-10-15 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/48587 * gfortran.dg/negative_unit2.f90: New testcase. From-SVN: r241199
2016-10-15revert: diagnostic.c (diagnostic_action_after_output): Remove max error ↵Nathan Sidwell4-44/+17
handling here .... Revert * diagnostic.c (diagnostic_action_after_output): Remove max error handling here .... (diagnostic_report_diagnostic): ... do it here instead. testsuite/ * c-c++-common/fmax-errors.c: Make sure note is emitted. From-SVN: r241198
2016-10-15runtime: copy runtime package time code from Go 1.7Ian Lance Taylor2-2/+2
Fix handling of function values for -fgo-c-header to generate FuncVal*, not simply FuncVal. While we're here change runtime.nanotime to use clock_gettime with CLOCK_MONOTONIC, rather than gettimeofday. This is what the gc library does. It provides nanosecond precision and a monotonic clock. Reviewed-on: https://go-review.googlesource.com/31232 From-SVN: r241197
2016-10-15Daily bump.GCC Administrator1-1/+1
From-SVN: r241196
2016-10-14runtime: copy mprof code from Go 1.7 runtimeIan Lance Taylor2-3/+14
Also create a gccgo version of some of the traceback code in traceback_gccgo.go, replacing some code currently in C. This required modifying the compiler so that when compiling the runtime package a slice expression does not cause a local array variable to escape to the heap. Reviewed-on: https://go-review.googlesource.com/31230 From-SVN: r241189
2016-10-14c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases and ↵Jason Merrill3-0/+19
__cpp_deduction_guides. * c-cppbuiltin.c (c_cpp_builtins): Define __cpp_aggregate_bases and __cpp_deduction_guides. From-SVN: r241188
2016-10-14Implement P0017R1, C++17 aggregates with bases.Jason Merrill12-33/+193
* class.c (build_base_field_1): Split out from... (build_base_field): ...here. In C++17 mode, build a field for empty bases. * decl.c (xref_basetypes): In C++17 aggregates can have bases. (next_initializable_field): Allow base fields in C++17. * typeck2.c (process_init_constructor_record): Likewise. From-SVN: r241187
2016-10-14diagnostic.c (diagnostic_action_after_output): Remove max error handling ↵Nathan Sidwell4-17/+44
here .... * diagnostic.c (diagnostic_action_after_output): Remove max error handling here .... (diagnostic_report_diagnostic): ... do it here instead. testsuite/ * c-c++-common/fmax-errors.c: Make sure note is emitted. From-SVN: r241186
2016-10-14Tweaks to print_rtx_functionDavid Malcolm3-11/+36
gcc/ChangeLog: * print-rtl-function.c (print_edge): Omit "(flags)" when none are set. (print_rtx_function): Update example in comment for... * print-rtl.c (print_rtx_operand_code_r): In compact mode, print non-virtual pseudos with a '%' sigil followed by the regno, offset by (LAST_VIRTUAL_REGISTER + 1), so that the first non-virtual pseudo is dumped as "%0". From-SVN: r241185
2016-10-14re PR middle-end/77959 (ICE in ix86_decompose_address, at i386/i386.c:14954)Jakub Jelinek4-0/+38
PR middle-end/77959 * expr.c (expand_expr_real_1) <case CONST_DECL>: For EXPAND_WRITE return a MEM. * gfortran.dg/pr77959.f90: New test. From-SVN: r241182
2016-10-14sparc-passes.def: New file.Eric Botcazou5-20/+41
* config/sparc/sparc-passes.def: New file. * config/sparc/t-sparc (PASSES_EXTRA): Add sparc-passes.def. * config/sparc/sparc-protos.h (make_pass_work_around_errata): New. * config/sparc/sparc.c (sparc_option_override): Don't register passes. From-SVN: r241180
2016-10-14DR 1511 - const volatile variables and ODRJakub Jelinek5-5/+83
DR 1511 - const volatile variables and ODR * decl.c (grokvardecl): Change flags argument to type_quals, add conceptp argument. Set TREE_PUBLIC for non-static volatile vars. (grokdeclarator): Adjust grokvardecl caller. * g++.dg/DRs/dr1511-1.C: New test. * g++.dg/DRs/dr1511-2.C: New test. From-SVN: r241176
2016-10-14debug7.adb (dg-options): Remove -g.Eric Botcazou4-3/+9
* gnat.dg/debug7.adb (dg-options): Remove -g. * gnat.dg/debug8.adb (dg-options): Add -margs. * gnat.dg/debug9.adb (dg-options): Remove -g and add -margs. From-SVN: r241174
2016-10-14loop-unroll.c (unroll_loop_runtime_iterations): Condition initial loop peel ↵Pat Haugen2-15/+31
to loops with exit test at the beginning. * loop-unroll.c (unroll_loop_runtime_iterations): Condition initial loop peel to loops with exit test at the beginning. From-SVN: r241173
2016-10-14runtime: just do file/line lookup in C, move Func to GoIan Lance Taylor1-1/+1
In order to port stack backtraces to Go, we need the ability to look up file/line information for PC values without allocating memory. This patch moves the handling of Func from C code to Go code, and simplifies the C code to just look up function/file/line/entry information for a PC. Reviewed-on: https://go-review.googlesource.com/31150 From-SVN: r241172
2016-10-14debug/elf: add sparc64 relocationsIan Lance Taylor1-1/+1
This is a backport of https://go-review.googlesource.com/30870. Reviewed-on: https://go-review.googlesource.com/30916 From-SVN: r241171
2016-10-14re PR rtl-optimization/68212 (Loop unroller breaks basic block frequencies)Pat Haugen3-4/+43
PR rtl-optimization/68212 * cfgloopmanip.c (duplicate_loop_to_header_edge): Use preheader edge frequency when computing scale factor for peeled copies. * loop-unroll.c (unroll_loop_runtime_iterations): Fix freq/count values for switch/peel blocks/edges. From-SVN: r241170
2016-10-14Move OVERRIDE/FINAL from gcc/coretypes.h to include/ansidecl.hPedro Alves2-25/+5
So that GDB and other projects that share the top level can use them. Bootstrapped with all default languages + jit on x86-64 Fedora 23. gcc/ChangeLog: 2016-10-14 Pedro Alves <palves@redhat.com> * coretypes.h (OVERRIDE, FINAL): Delete, moved to include/ansidecl.h. include/ChangeLog: 2016-10-14 Pedro Alves <palves@redhat.com> * ansidecl.h (GCC_FINAL): Delete. (OVERRIDE, FINAL): New, moved from gcc/coretypes.h. From-SVN: r241166
2016-10-14mips.c (mips_prepare_pch_save): Initialize micromips_globals to zero.Catherine Moore2-17/+24
2016-10-13 Catherine Moore <clm@codesourcery.com> * gcc/config/mips/mips.c (mips_prepare_pch_save): Initialize micromips_globals to zero. From-SVN: r241165
2016-10-14runtime: copy cpuprof code from Go 1.7 runtimeIan Lance Taylor3-61/+59
This replaces runtime/cpuprof.goc with go/runtime/cpuprof.go and adjusts the supporting code in runtime/proc.c. This adds another case where the compiler needs to avoid heap allocation in the runtime package: when evaluating a method expression into a closure. Implementing this required moving the relevant code from do_get_backend to do_flatten, so that I could easily add a temporary variable. Doing that let me get rid of Bound_method_expression::do_lower. Reviewed-on: https://go-review.googlesource.com/31050 From-SVN: r241163
2016-10-14re PR tree-optimization/77979 (ICE on valid code at -Os and above on ↵Richard Biener4-2/+36
x86_64-linux-gnu: Segmentation fault) 2016-10-14 Richard Biener <rguenther@suse.de> PR tree-optimization/77979 * tree-vrp.c (compare_name_with_value): Handle released SSA names in the equivalency sets. (compare_names): Likewise. * gcc.dg/torture/pr77979.c: New testcase. From-SVN: r241162
2016-10-14Test folding of str{n}{case}cmp and memchrMartin Liska4-0/+266
* gcc.dg/tree-ssa/builtins-folding-generic.c: New test. * gcc.dg/tree-ssa/builtins-folding-gimple.c: Likewise. * gcc.dg/tree-ssa/builtins-folding-gimple-ub.c: Likewise. From-SVN: r241161
2016-10-14Fold __builtin_memchr functionMartin Liska5-59/+119
* builtins.h(target_char_cst_p): Declare the function. * builtins.c (fold_builtin_memchr): Remove. (target_char_cst_p): Move the function from gimple-fold.c. (fold_builtin_3): Do not call the function. * gimple-fold.c (gimple_fold_builtin_memchr): New function. (gimple_fold_builtin): Call the function. * fold-const-call.c (fold_const_call_1): Handle CFN_BUILT_IN_MEMCHR. From-SVN: r241160
2016-10-14Fold __builtin_str{n}{case}cmp functionsMartin Liska5-147/+239
* builtins.c (fold_builtin_strcmp): Remove function. (fold_builtin_strncmp): Likewise. (fold_builtin_2): Remove call of the function. (fold_builtin_3): Likewise. * fold-const-call.c (fold_const_call): Add constant folding for CFN_BUILT_IN_STRCASECMP and CFN_BUILT_IN_STRNCASECMP. * fold-const-call.h (build_cmp_result): Declare the function. * gimple-fold.c (gimple_load_first_char): New function. (gimple_fold_builtin_string_compare): Likewise. (gimple_fold_builtin): Call the function. From-SVN: r241159
2016-10-14Fix gcc.dg/torture/pr77937-[12].c for real.Uros Bizjak3-2/+10
2016-10-14 Uros Bizjak <ubizjak@gmail.com> * gcc.dg/torture/pr77937-1.c: Move -O3 to dg-options. Pass -march=amdfam10 for both i?86-?-* and x86_64-*-*. * gcc.dg/torture/pr77937-2.c: Likewise. From-SVN: r241157
2016-10-14Fix pr77937-1.c and pr77937-2.c testcasesMarkus Trippelsdorf2-2/+2
From-SVN: r241156
2016-10-14* gcov-io.c (gcov_open): Deconstify 'mode'.Nathan Sidwell2-1/+5
From-SVN: r241155
2016-10-14re PR ada/77968 (ICEs with -flto on gnat.dg)Eric Botcazou17-71/+203
PR ada/77968 * gcc-interface/utils.c (create_var_decl): Do not clear TREE_READONLY in LTO mode for an external variable. (can_materialize_object_renaming_p): Move up. From-SVN: r241154
2016-10-14Support only \0-terminated string in c_getstr and returnMartin Liska3-10/+36
* fold-const.c (c_getstr): Support of properly \0-terminated string constants. New argument is added. * fold-const.h: New argument is added. From-SVN: r241152
2016-10-14coarray_38.f90: Expect error message.Andre Vehreschild4-1/+23
gcc/testsuite/ChangeLog: 2016-10-14 Andre Vehreschild <vehre@gcc.gnu.org> * gfortran.dg/coarray_38.f90: Expect error message. gcc/fortran/ChangeLog: 2016-10-14 Andre Vehreschild <vehre@gcc.gnu.org> * resolve.c (resolve_symbol): Add unimplemented message for polymorphic types with allocatable/pointer components and coarray=lib. From-SVN: r241150
2016-10-14[AArch64] Add spellchecking hints for -march,-mcpu,-mtune and their attributesKyrylo Tkachov9-1/+127
* config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): New function. (aarch64_print_hint_for_core): Likewise. (aarch64_print_hint_for_arch): Likewise. (aarch64_validate_march): Use it. Fix indentation in type signature. (aarch64_validate_mcpu): Use aarch64_print_hint_for_core_or_arch. (aarch64_validate_mtune): Likewise. (aarch64_handle_attr_arch): Likewise. (aarch64_handle_attr_cpu): Likewise. (aarch64_handle_attr_tune): Likewise. * gcc.target/aarch64/spellcheck_1.c: New test. * gcc.target/aarch64/spellcheck_2.c: Likewise. * gcc.target/aarch64/spellcheck_3.c: Likewise. * gcc.target/aarch64/spellcheck_4.c: Likewise. * gcc.target/aarch64/spellcheck_5.c: Likewise. * gcc.target/aarch64/spellcheck_6.c: Likewise. From-SVN: r241149
2016-10-14Fix long lineEric Botcazou1-2/+2
From-SVN: r241148
2016-10-14optabs.def: Remove optab function gen_int_libfunc for sdivmod_optab and ↵Prathamesh Kulkarni2-2/+7
udivmod_optab. 2016-10-14 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org> * optabs.def: Remove optab function gen_int_libfunc for sdivmod_optab and udivmod_optab. From-SVN: r241147
2016-10-14Daily bump.GCC Administrator1-1/+1
From-SVN: r241146
2016-10-13PR c++/71912 - [6/7 regression] flexible array in struct in union rejectedMartin Sebor10-105/+895
gcc/cp/ChangeLog: PR c++/71912 * class.c (struct flexmems_t): Add members. (find_flexarrays): Add arguments. Correct handling of anonymous structs. (diagnose_flexarrays): Adjust to issue warnings in addition to errors. (check_flexarrays): Add argument. (diagnose_invalid_flexarray): New functions. gcc/testsuite/ChangeLog: PR c++/71912 * g++.dg/ext/flexary4.C: Adjust. * g++.dg/ext/flexary5.C: Same. * g++.dg/ext/flexary9.C: Same. * g++.dg/ext/flexary19.C: New test. * g++.dg/ext/flexary18.C: New test. * g++.dg/torture/pr64312.C: Add a dg-error directive to an ill-formed regression test. * g++.dg/compat/struct-layout-1_generate.c (subfield): Add argument. Avoid generating a flexible array member in an array. From-SVN: r241143
2016-10-13m68k.c (m68k_option_override): Check opt_fstack_limit_symbol_arg and ↵Andreas Schwab4-3/+15
opt_fstack_limit_register_no instead of... gcc/ * config/m68k/m68k.c (m68k_option_override): Check opt_fstack_limit_symbol_arg and opt_fstack_limit_register_no instead of stack_limit_rtx. gcc/testsuite/ * gcc.target/m68k/stack-limit-1.c: Expect warning on line 0. From-SVN: r241140
2016-10-13re PR tree-optimization/77937 (ICE: in replace_one_candidate, at ↵Bill Schmidt3-0/+37
gimple-ssa-strength-reduction.c:3370) 2016-10-13 Bill Schmidt <wschmidt@linux.vnet.ibm.com> PR tree-optimization/77937 * gcc.dg/torture/pr77937-1.c: New. * gcc.dg/torture/pr77937-2.c: New. From-SVN: r241139
2016-10-13Implement P0386R2 - C++17 inline variablesJason Merrill20-31/+712
2016-10-11 Jakub Jelinek <jakub@redhat.com> * dwarf2out.c (gen_member_die): Handle inline static data member definitions. c-family/ * c-cppbuiltin.c (c_cpp_builtins): Add __cpp_inline_variables. cp/ * cp-tree.h (struct lang_type): Shrink language field to 1 bit from 4. Add var_declared_inline_p field. Mention 2 spare bits. (DECL_VAR_DECLARED_INLINE_P): Define. (SET_DECL_VAR_DECLARED_INLINE_P): Define. (DECL_INLINE_VAR_P): Define. (diagnose_inline_vars_for_namespace): Declare. * decl.c (diagnose_inline_vars_for_namespace): New function. (duplicate_decls): For static data members copy DECL_DECLARED_CONSTEXPR_P. (redeclaration_error_message): Handle C++17 redundant redeclaration of constexpr static data member outside of class. (maybe_commonize_var): Handle inline variables. (check_initializer): Ignore inline variables for diagnostics. Adjust diagnostic wording for C++17. (make_rtl_for_nonlocal_decl): Allow in-class definition of inline static data members. (bad_specifiers): Don't diagnose inline on variables here. (grokvardecl): Add inlinep argument, non-static const inline variables are TREE_PUBLIC. (check_static_variable_definition): Return early also for inline variables. (grokdeclarator): Handle inline variables and inline static data members. * typeck2.c (store_init_value): Don't diagnose non-constant initializers for non-constexpr inline static data members. * decl2.c (vague_linkage_p): Return true for inline variables. (c_parse_final_cleanups): In-class declaration of inline static data members is a definition. Call diagnose_inline_vars_for_namespace through walk_namespaces. * pt.c (instantiate_decl): Set pattern_defined for in-class definitions of inline static data members. From-SVN: r241137
2016-10-13gcov-io.c (gcov_open): Fix documentation.Nathan Sidwell2-37/+17
* gcov-io.c (gcov_open): Fix documentation. Simplify setting gcov_var.mode. Remove unnecessary fstat. From-SVN: r241136