gcc.git
8 years agore PR debug/77692 (gcc.dg/debug/dwarf2/const-2b.c FAILs)
Richard Biener [Mon, 26 Sep 2016 07:33:33 +0000 (07:33 +0000)]
re PR debug/77692 (gcc.dg/debug/dwarf2/const-2b.c FAILs)

2016-09-26  Richard Biener  <rguenther@suse.de>

PR debug/77692
* cgraphunit.c (analyze_functions): Before early removing
global vars calls the late_global_decl debug handler mark
the variable as readonly.

From-SVN: r240483

8 years agoDaily bump.
GCC Administrator [Mon, 26 Sep 2016 00:16:14 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r240482

8 years agodebug.cc: Include debug/vector.
François Dumont [Sun, 25 Sep 2016 20:26:02 +0000 (20:26 +0000)]
debug.cc: Include debug/vector.

2016-09-25  François Dumont  <fdumont@gcc.gnu.org>

* src/c++11/debug.cc: Include debug/vector. Include cctype. Remove
functional.
(get_safe_base_mutex): Get mutex based on address lowest non nil bits.
* testsuite/23_containers/vector/debug/mutex_association.cc: New.

From-SVN: r240479

8 years agobitset (bitset::reference::reference(const _Base_ref&, bitset*)): Remove __unused__...
François Dumont [Sun, 25 Sep 2016 20:15:21 +0000 (20:15 +0000)]
bitset (bitset::reference::reference(const _Base_ref&, bitset*)): Remove __unused__ attribute.

2016-09-25  François Dumont  <fdumont@gcc.gnu.org>

* include/debug/bitset (bitset::reference::reference(const _Base_ref&,
bitset*)): Remove __unused__ attribute.
* include/debug/safe_base.h (_Safe_iterator_base): Make
_Safe_sequence_base a friend.
(_Safe_iterator_base::_M_attach): Make protected.
(_Safe_iterator_base::_M_attach_single): Likewise.
(_Safe_iterator_base::_M_detach): Likewise.
(_Safe_iterator_base::_M_detach_single): Likewise.
(_Safe_sequence_base): Make _Safe_iterator_base a friend.
(_Safe_sequence_base::_Safe_sequence_base(_Safe_sequence_base&&)): New.
(_Safe_sequence_base::_M_swap): Make protected.
(_Safe_sequence_base::_M_attach): Make private.
(_Safe_sequence_base::_M_attach_single): Likewise.
(_Safe_sequence_base::_M_detach): Likewise.
(_Safe_sequence_base::_M_detach_single): Likewise.
* include/debug/safe_container.h
(_Safe_container::_Safe_container(_Safe_container&&)): Make default.
* include/debug/safe_iterator.h
(_Safe_iterator::operator++()): Name __scoped_lock instance.
* include/debug/safe_iterator.tcc: Remove trailing line.
* include/debug/safe_unordered_base.h
(_Safe_local_iterator_base::_M_attach): Make protected.
(_Safe_local_iterator_base::_M_attach_single): Likewise.
(_Safe_local_iterator_base::_M_detach): Likewise.
(_Safe_local_iterator_base::_M_detach_single): Likewise.
(_Safe_unordered_container_base): Make _Safe_local_iterator_base friend.
(_Safe_unordered_container_base::_M_attach_local): Make private.
(_Safe_unordered_container_base::_M_attach_local_single): Likewise.
(_Safe_unordered_container_base::_M_detach_local): Likewise.
(_Safe_unordered_container_base::_M_detach_local_single): Likewise.

From-SVN: r240478

8 years agore PR fortran/77429 (ICE in gfc_check_dependency, at fortran/dependency.c:1261)
Steven G. Kargl [Sun, 25 Sep 2016 18:46:28 +0000 (18:46 +0000)]
re PR fortran/77429 (ICE in gfc_check_dependency, at fortran/dependency.c:1261)

2016-09-25  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/77429
* dependency.c (gfc_check_dependency):  Convert gcc_assert() to
a conditional and possible call to  gfc_internal_error().

2016-09-25  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/77429
* gfortran.dg/pr77429.f90: New test.

From-SVN: r240477

8 years agore PR fortran/77694 (ICE in optimize_binop_array_assignment, at fortran/frontend...
Steven G. Kargl [Sun, 25 Sep 2016 17:30:27 +0000 (17:30 +0000)]
re PR fortran/77694 (ICE in optimize_binop_array_assignment, at fortran/frontend-passes.c:1080)

2016-09-22  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/77694
* frontend-passes.c (optimize_binop_array_assignment): Check pointer
for NULL.

2016-09-22  Steven G. Kargl  <kargl@gcc.gnu.org>

PR fortran/77694
* gfortran.dg/pr77694.f90: New test.

From-SVN: r240476

8 years ago* gcc.target/i386/pr77621.c (dg-options): Add -mno-avx.
Uros Bizjak [Sun, 25 Sep 2016 15:29:06 +0000 (17:29 +0200)]
* gcc.target/i386/pr77621.c (dg-options): Add -mno-avx.

From-SVN: r240474

8 years agoalgo.h: Generalize usage of std::__iterator_category.
François Dumont [Sun, 25 Sep 2016 15:23:45 +0000 (15:23 +0000)]
algo.h: Generalize usage of std::__iterator_category.

2016-09-25  François Dumont  <fdumont@gcc.gnu.org>

* include/parallel/algo.h: Generalize usage of std::__iterator_category.
Adjust whitespaces.

From-SVN: r240473

8 years agoThis fixes a fallout that actually goes back to 5.0 but went unnoticed.
Oleg Endo [Sun, 25 Sep 2016 06:59:37 +0000 (06:59 +0000)]
This fixes a fallout that actually goes back to 5.0 but went unnoticed.

The costs for movt and movrt type of insns were not correctly reported
and ifcvt thus made some bad choices for SH.  A new cset_zero pattern
variant is also required to fix the matching for some recent changes
in the middle end.

gcc/
PR target/51244
* config/sh/sh.c (sh_movt_set_dest, sh_movrt_set_dest): Add overloads.
(sh_rtx_costs): Handle SET of movt and movrt patterns.
* cnofig/sh/sh-protos.h (sh_movt_set_dest, sh_movrt_set_dest): Forward
declare new overloads.
* config/sh/sh.md (*cset_zero): Add variant that takes a treg_set_expr
operand.

gcc/testsuite/
PR target/51244
* gcc.target/sh/pr51244-11.c: Add more detailed expected insn matching.

From-SVN: r240471

8 years agoDaily bump.
GCC Administrator [Sun, 25 Sep 2016 00:16:16 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r240470

8 years agocoarray_lib_comm_1.f90: Really fix test for 32-bit mode.
Dominique d'Humieres [Sat, 24 Sep 2016 18:32:48 +0000 (20:32 +0200)]
coarray_lib_comm_1.f90: Really fix test for 32-bit mode.

2016-09-24  Dominique d'Humieres  <dominiq@lps.ens.fr>

* gfortran.dg/coarray_lib_comm_1.f90: Really fix test
for 32-bit mode.

From-SVN: r240467

8 years agors6000.c (expand_block_compare, [...]): Change TARGET_LITTLE_ENDIAN to !BYTES_BIG_ENDIAN.
Aaron Sawdey [Sat, 24 Sep 2016 18:14:21 +0000 (18:14 +0000)]
rs6000.c (expand_block_compare, [...]): Change TARGET_LITTLE_ENDIAN to !BYTES_BIG_ENDIAN.

2016-09-24  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>

* config/rs6000/rs6000.c (expand_block_compare, do_load_for_compare):
Change TARGET_LITTLE_ENDIAN to !BYTES_BIG_ENDIAN.

From-SVN: r240466

8 years agoconfigure.ac (gcc_cv_as_aix_dwloc): Fix typo in assembly fragment.
David Edelsohn [Sat, 24 Sep 2016 16:59:18 +0000 (12:59 -0400)]
configure.ac (gcc_cv_as_aix_dwloc): Fix typo in assembly fragment.

        * configure.ac (gcc_cv_as_aix_dwloc): Fix typo in assembly fragment.
        * configure: Regenerate.

From-SVN: r240465

8 years agoAdd missing changelong entry for 240455
Aaron Sawdey [Sat, 24 Sep 2016 16:23:16 +0000 (11:23 -0500)]
Add missing changelong entry for 240455

From-SVN: r240464

8 years agocoarray_lib_comm_1.f90: Fix test for 32-bit mode.
Dominique d'Humieres [Sat, 24 Sep 2016 15:12:55 +0000 (17:12 +0200)]
coarray_lib_comm_1.f90: Fix test for 32-bit mode.

2016-09-24  Dominique d'Humieres  <dominiq@lps.ens.fr>

* gfortran.dg/coarray_lib_comm_1.f90: Fix test
for 32-bit mode.

From-SVN: r240463

8 years agore PR c/77490 (bit-not (~) on boolean should be warned about)
Marek Polacek [Sat, 24 Sep 2016 09:39:23 +0000 (09:39 +0000)]
re PR c/77490 (bit-not (~) on boolean should be warned about)

PR c/77490
* c.opt (Wbool-operation): New.

* c-typeck.c (build_unary_op): Warn about bit not on expressions that
have boolean value.  Warn about ++/-- on booleans.

* typeck.c (cp_build_unary_op): Warn about bit not on expressions that
have boolean value.

* doc/invoke.texi: Document -Wbool-operation.

* c-c++-common/Wbool-operation-1.c: New test.
* gcc.dg/Wbool-operation-1.c: New test.

From-SVN: r240462

8 years agoDaily bump.
GCC Administrator [Sat, 24 Sep 2016 00:16:14 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r240461

8 years agolang.opt, [...]: New flag -fdec-static.
Fritz Reese [Fri, 23 Sep 2016 21:06:18 +0000 (21:06 +0000)]
lang.opt, [...]: New flag -fdec-static.

2016-09-23  Fritz Reese  <fritzoreese@gmail.com>

gcc/fortran/
* lang.opt, invoke.texi, gfortran.texi: New flag -fdec-static.
* options.c (set_dec_flags): Set -fdec-static with -fdec.
* gfortran.h (symbol_attribute): New attribute automatic.
* gfortran.h (gfc_add_automatic): New prototype.
* match.h (gfc_match_automatic, gfc_match_static): New functions.
* decl.c (gfc_match_automatic, gfc_match_static): Ditto.
* symbol.c (gfc_add_automatic): Ditto.
* decl.c (match_attr_spec): Match AUTOMATIC and STATIC decls.
* parse.c (decode_specification_statement, decode_statement): Ditto.
* resolve.c (apply_default_init_local, resolve_fl_variable_derived,
resolve_symbol): Support for automatic attribute.
* symbol.c (check_conflict, gfc_copy_attr, gfc_is_var_automatic):
Ditto.
* trans-decl.c (gfc_finish_var_decl): Ditto.

gcc/testsuite/gfortran.dg/
* dec_static_1.f90, dec_static_2.f90, dec_static_3.f90,
dec_static_4.f90: New testcases.

From-SVN: r240458

8 years agointernal/syscall/unix: add getrandom syscall for MIPS and SPARC
Ian Lance Taylor [Fri, 23 Sep 2016 21:00:43 +0000 (21:00 +0000)]
internal/syscall/unix: add getrandom syscall for MIPS and SPARC

    Reviewed-on: https://go-review.googlesource.com/29678

From-SVN: r240457

8 years agore PR fortran/48298 ([F03] User-Defined Derived-Type IO (DTIO))
Jerry DeLisle [Fri, 23 Sep 2016 20:36:21 +0000 (20:36 +0000)]
re PR fortran/48298 ([F03] User-Defined Derived-Type IO (DTIO))

2016-09-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

PR libgfortran/48298
* io/inquire.c (inquire_via_unit): Adjust error check for the
two possible internal unit KINDs.
* io/io.h: Adjust defines for is_internal_unit and
is_char4_unit. (gfc_unit): Add internal unit data to structure.
(get_internal_unit): Change declaration to set_internal_unit.
(free_internal_unit): Change name to stash_internal_unit_number.
(get_unique_unit_number): Adjust parameter argument.
Define IOPARM_DT_HAS_UDTIO. (gfc_saved_unit): New structure.
* io/list_read.c (next_char_internal): Use is_char4_unit.
* io/open.c (st_open): Adjust call to get_unique_unit_number.
* io/transfer.c (write_block): Use is_char4_unit.
(data_transfer_init): Update check for unit numbers.
(st_read_done): Free the various allocated memories used for the
internal units and stash the negative unit number and pointer to unit
structure to allow reuse. (st_write_done): Likewise stash the freed
unit.
* io/unit.c: Create a fixed size buffer of 16 gfc_saved_unit's to use
as a stack to save newunit unit numbers and unit structure for reuse.
(get_external_unit): Change name to get_gfc_unit to better
reflect what it does. (find_unit): Change call to get_gfc_unit.
(find_or_create_unit): Likewise. (get_internal_unit): Change
name to set_internal_unit. Move internal unit from the dtp
structure to the gfc_unit structure so that it can be passed to
child I/O statements through the UNIT.
(free_internal_unit): Change name to stash_internal_unit_number.
Push the common.unit number onto the newunit stack, saving it
for possible reuse later. (get_unit): Set the internal unit
KIND. Use get_unique_unit_number to get a negative unit number
for the internal unit. Use get_gfc_unit to get the unit structure
and use set_internal_unit to initialize it.
(init_units): Initialize the newunit stack.
(get_unique_unit_number): Check the stack for an available unit
number and use it. If none there get the next most negative
number. (close_units): Free any unit structures pointed to from the save
stack.

2016-09-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

PR fortran/48298
* gfortran.h (gfc_dt): Add *udtio.
* ioparm.def: Add bit IOPARM_dt_f2003 to align with library use of bit
25. Add IOPARM_dt_dtio bit to common flags.
* resolve.c (resolve_transfer): Set dt->udtio to expression.
* io.c (gfc_match_inquire): Adjust error message for internal
unit KIND.
* libgfortran.h: Adjust defines for GFC_INTERNAL_UNIT4,
GFC_INTERNAL_UNIT, and GFC_INVALID_UNIT.
* trans-io.c (build_dt): Set common_unit to reflect the KIND of
the internal unit. Set mask bit for presence of dt->udtio.

2016-09-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>

PR fortran/48298
* gfortran.dg/negative_unit_check.f90: Update test.
* gfortran.dg/dtio_14.f90: New test.

From-SVN: r240456

8 years agors6000.md (cmpmemsi): New define_expand.
Aaron Sawdey [Fri, 23 Sep 2016 20:34:26 +0000 (15:34 -0500)]
rs6000.md (cmpmemsi): New define_expand.

* config/rs6000/rs6000.md (cmpmemsi): New define_expand.
* config/rs6000/rs6000.c (expand_block_compare): New function used by
cmpmemsi pattern to do builtin expansion of memcmp ().
(compute_current_alignment): Add helper function for
expand_block_compare used to compute alignment as the compare proceeds.
(select_block_compare_mode): Used by expand_block_compare to select
the mode used for reading the next chunk of bytes in the compare.
(do_load_for_compare): Used by expand_block_compare to emit the load
insns for the compare.
(rs6000_emit_dot_insn): Moved this function to avoid a forward
reference from expand_block_compare ().
* config/rs6000/rs6000-protos.h (expand_block_compare): Add a
prototype for this function.
* config/rs6000/rs6000.opt (mblock-compare-inline-limit): Add a new
target option for controlling how much code inline expansion of
memcmp() will be allowed to generate.

From-SVN: r240455

8 years agoS/390: Fix hotpatch test cases.
Dominik Vogt [Fri, 23 Sep 2016 19:37:06 +0000 (19:37 +0000)]
S/390: Fix hotpatch test cases.

The attached patch fixes some dg-error tests that were broken since
the recent change of the error location.

gcc/testsuite/ChangeLog:

* gcc.target/s390/hotpatch-compile-1.c: Fixed dg-error test.
* gcc.target/s390/hotpatch-compile-2.c: Likewise.
* gcc.target/s390/hotpatch-compile-3.c: Likewise.
* gcc.target/s390/hotpatch-compile-4.c: Likewise.
* gcc.target/s390/hotpatch-compile-5.c: Likewise.
* gcc.target/s390/hotpatch-compile-6.c: Likewise.
* gcc.target/s390/hotpatch-compile-14.c: Likewise.

From-SVN: r240454

8 years agocompiler: better abstraction layer for diagnostics.
Than McIntosh [Fri, 23 Sep 2016 19:36:45 +0000 (19:36 +0000)]
compiler: better abstraction layer for diagnostics.

    Introduce an abstraction layer for reporting diagnostics, so as to avoid
    directly using the native GCC interfaces such as "error_at",
    "warning_at", "open_quote", "close_quote", etc.  The new interfaces have
    the same look and feel as the GCC equivalents, but make calls into
    back-end functions to allow the back end to select the proper final
    reporting routine.

    Reviewed-on: https://go-review.googlesource.com/29191

* go-gcc-diagnostics.cc: New file.
* go-location.h (Location): Remove operator source_location.  Add
operator==.
* go-system.h: #include <sstream>.
* Make-lang.in (GO_OBJS): Add go/go-diagnostics.o and
go/go-gcc-diagnostics.o.
(CFLAGS-go/go-gcc-diagnostics.o): New variable.

From-SVN: r240453

8 years agohooks.c (hook_bool_bool_false, [...]): For arguments with ATTRIBUTE_UNUSED...
Jakub Jelinek [Fri, 23 Sep 2016 18:08:43 +0000 (20:08 +0200)]
hooks.c (hook_bool_bool_false, [...]): For arguments with ATTRIBUTE_UNUSED...

* hooks.c (hook_bool_bool_false, hook_bool_bool_gcc_optionsp_false,
hook_bool_mode_false, hook_bool_mode_true,
hook_bool_mode_const_rtx_false, hook_bool_mode_const_rtx_true,
hook_bool_mode_rtx_false, hook_bool_mode_rtx_true,
hook_bool_const_rtx_insn_const_rtx_insn_true,
hook_bool_mode_uhwi_false, hook_void_FILEptr_constcharptr,
hook_bool_FILEptr_rtx_false, hook_bool_gsiptr_false,
hook_bool_const_tree_hwi_hwi_const_tree_false,
hook_bool_const_tree_hwi_hwi_const_tree_true,
default_can_output_mi_thunk_no_vcall, hook_int_uint_mode_1,
hook_int_const_tree_0, hook_int_const_tree_const_tree_1,
hook_int_rtx_0, hook_int_rtx_bool_0, hook_void_tree,
hook_void_constcharptr, hook_void_tree_treeptr, hook_void_int_int,
hook_bool_tree_false, hook_bool_const_tree_false, hook_bool_tree_true,
hook_bool_const_tree_true, hook_bool_tree_tree_false,
hook_bool_tree_tree_true, hook_bool_tree_bool_false,
hook_bool_rtx_insn_true, hook_bool_rtx_false,
hook_bool_uintp_uintp_false,
hook_bool_rtx_mode_int_int_intp_bool_false, hook_rtx_rtx_null,
hook_rtx_tree_int_null, hook_uint_mode_0,
hook_constcharptr_const_tree_null, hook_tree_tree_int_treep_bool_null,
hook_tree_tree_tree_null, hook_tree_tree_tree_tree_null,
hook_constcharptr_const_rtx_insn_null,
hook_constcharptr_const_tree_const_tree_null,
hook_constcharptr_int_const_tree_null,
hook_constcharptr_int_const_tree_const_tree_null,
hook_tree_const_tree_null, hook_bool_rtx_insn_int_false,
hook_void_rtx_insn_int, hook_void_gcc_optionsp): For arguments with
ATTRIBUTE_UNUSED, remove parameter name as well as ATTRIBUTE_UNUSED.

From-SVN: r240452

8 years agore PR go/77701 (suspicious code in go/go-gcc.cc)
Chris Manghane [Fri, 23 Sep 2016 17:55:53 +0000 (17:55 +0000)]
re PR go/77701 (suspicious code in go/go-gcc.cc)

PR go/77701
* go-gcc.cc (Gcc_backend::Gcc_backend): Fix calls to integer_type
to pass arguments in the correct order.

From-SVN: r240451

8 years agore PR testsuite/77713 (gcc.dg/tree-ssa/builtin-sprintf.c compilation failed to produc...
Martin Sebor [Fri, 23 Sep 2016 17:55:29 +0000 (17:55 +0000)]
re PR testsuite/77713 (gcc.dg/tree-ssa/builtin-sprintf.c compilation failed to produce executable)

gcc/testsuite/ChangeLog:

PR testsuite/77713
* gcc.dg/tree-ssa/builtin-sprintf.c (test_e_long_double): Avoid
assuming long double is bigger than double.

From-SVN: r240450

8 years agoImplement P0138R2, C++17 construction rules for enum class values
Jakub Jelinek [Fri, 23 Sep 2016 17:38:29 +0000 (19:38 +0200)]
Implement P0138R2, C++17 construction rules for enum class values

Implement P0138R2, C++17 construction rules for enum class values
* cp-tree.h (is_direct_enum_init): Declare.
* decl.c (is_direct_enum_init): New function.
(reshape_init): Use it.
* typeck.c (convert_for_assignment): Likewise.

* g++.dg/cpp1z/direct-enum-init1.C: New test.

From-SVN: r240449

8 years agoMake-lang.in (check-c++1z): Pass RUNTESTFLAGS down to make check-g++.
Jakub Jelinek [Fri, 23 Sep 2016 17:32:38 +0000 (19:32 +0200)]
Make-lang.in (check-c++1z): Pass RUNTESTFLAGS down to make check-g++.

* Make-lang.in (check-c++1z): Pass RUNTESTFLAGS down to
make check-g++.

From-SVN: r240448

8 years agoAvoid reallocation for basic_string::clear()
Jonathan Wakely [Fri, 23 Sep 2016 17:25:34 +0000 (18:25 +0100)]
Avoid reallocation for basic_string::clear()

PR libstdc++/56166
PR libstdc++/77582
* include/bits/basic_string.h (basic_string::clear()): Drop reference
and use empty rep.
* include/ext/rc_string_base.h (__rc_string_base::_M_clear()):
Likewise.
* testsuite/21_strings/basic_string/56166.cc: New.
* testsuite/ext/vstring/modifiers/clear/56166.cc: New.

From-SVN: r240447

8 years agoOptimize truncating a basic_string
Jonathan Wakely [Fri, 23 Sep 2016 17:25:23 +0000 (18:25 +0100)]
Optimize truncating a basic_string

* include/bits/basic_string.h [_GLIBCXX_USE_CXX11_ABI]
(basic_string::erase(size_type, size_type)): Add fast path for
truncating the string, by calling _M_set_length directly.
(basic_string::erase(__const_iterator, __const_iterator)): Likewise.
* include/bits/basic_string.tcc [_GLIBCXX_USE_CXX11_ABI]
(basic_string::resize(size_type, _CharT)): Likewise.

From-SVN: r240446

8 years agovec.h (vNULL): Extend comment to say = vNULL initialization isn't needed for static...
Jakub Jelinek [Fri, 23 Sep 2016 16:59:14 +0000 (18:59 +0200)]
vec.h (vNULL): Extend comment to say = vNULL initialization isn't needed for static vars.

* vec.h (vNULL): Extend comment to say = vNULL initialization
isn't needed for static vars.

From-SVN: r240445

8 years agosel-sched-ir.c (sel_global_bb_info, [...]): Remove unnecessary = vNULL initialization...
Jakub Jelinek [Fri, 23 Sep 2016 16:58:40 +0000 (18:58 +0200)]
sel-sched-ir.c (sel_global_bb_info, [...]): Remove unnecessary = vNULL initialization of file scope vec.

* sel-sched-ir.c (sel_global_bb_info, sel_region_bb_info,
loop_nests, s_i_d, last_added_blocks): Remove unnecessary
= vNULL initialization of file scope vec.
* passes.c (pass_tab, enabled_pass_uid_range_tab,
disabled_pass_uid_range_tab): Likewise.
* haifa-sched.c (sched_luids, h_i_d): Likewise.
* tree-chkp-opt.c (check_infos): Likewise.
* sel-sched.c (vec_av_set, vec_temp_moveop_nops): Likewise.
c/
* c-parser.c (incomplete_record_decls): Remove unnecessary
= vNULL initialization of file scope vec.
cp/
* constexpr.c (call_stack): Remove unnecessary
= vNULL initialization of file scope vec.

From-SVN: r240444

8 years agovec.h (vnull::operator vec): Add constexpr keyword for C++11 and later.
Jakub Jelinek [Fri, 23 Sep 2016 16:57:23 +0000 (18:57 +0200)]
vec.h (vnull::operator vec): Add constexpr keyword for C++11 and later.

* vec.h (vnull::operator vec): Add constexpr keyword for
C++11 and later.

From-SVN: r240443

8 years agoFix gcc.dg/tree-ssa/builtin-sprintf-warn-4.c
David Malcolm [Fri, 23 Sep 2016 16:55:27 +0000 (16:55 +0000)]
Fix gcc.dg/tree-ssa/builtin-sprintf-warn-4.c

gcc/testsuite/ChangeLog
PR preprocessor/77672
* gcc.dg/tree-ssa/builtin-sprintf-warn-4.c (test): Update
expected multiline output from first warning to reflect change
in r240434.

From-SVN: r240442

8 years agobuiltin-sprintf-warn-2.c: Fix xfail pattern.
Thomas Preud'homme [Fri, 23 Sep 2016 16:06:57 +0000 (16:06 +0000)]
builtin-sprintf-warn-2.c: Fix xfail pattern.

2016-09-23  Thomas Preud'homme  <thomas.preudhomme@arm.com>

    gcc/testsuite/
    * gcc.dg/tree-ssa/builtin-sprintf-warn-2.c: Fix xfail pattern.

From-SVN: r240441

8 years agoFix incorrect file in ChangeLog on previous commit
Matthew Fortune [Fri, 23 Sep 2016 15:51:54 +0000 (15:51 +0000)]
Fix incorrect file in ChangeLog on previous commit

gcc/
* tree-ssa-loop-prefetch.c (issue_prefetch_ref): Add call
to duplicate_ssa_name_ptr_info.

From-SVN: r240440

8 years agoEnsure points-to information is maintained for prefetch.
Doug Gilmore [Fri, 23 Sep 2016 15:48:01 +0000 (15:48 +0000)]
Ensure points-to information is maintained for prefetch.

gcc/
        PR tree-optimization/77654
        * tree-ssa-alias.c (issue_prefetch_ref): Add call
        to duplicate_ssa_name_ptr_info.

From-SVN: r240439

8 years agore PR testsuite/77411 (object-size-9.c -fpic -m32 failure)
Bernd Edlinger [Fri, 23 Sep 2016 14:43:45 +0000 (14:43 +0000)]
re PR testsuite/77411 (object-size-9.c -fpic -m32 failure)

2016-09-23  Bernd Edlinger  <bernd.edlinger@hotmail.de>
            Tom de Vries  <tom@codesourcery.com>

        PR testsuite/77411
        * c-c++-common/ubsan/object-size-9.c: Call __builtin_exit in C++.

Co-Authored-By: Tom de Vries <tom@codesourcery.com>
From-SVN: r240437

8 years agoatomic-12.c: Skip for C++1z.
Marek Polacek [Fri, 23 Sep 2016 14:40:16 +0000 (14:40 +0000)]
atomic-12.c: Skip for C++1z.

* c-c++-common/gomp/atomic-12.c: Skip for C++1z.
* c-c++-common/gomp/atomic-13.c: Likewise.
* c-c++-common/gomp/atomic-14.c: Likewise.
* c-c++-common/pr60439.c: Remove invalid code.
* g++.dg/expr/bitfield4.C: Robustify for C++1z.
* g++.dg/expr/bitfield5.C: Likewise.
* g++.dg/expr/bitfield6.C: Likewise.
* g++.dg/expr/bool1.C: Likewise.
* g++.dg/expr/bool3.C: Likewise.
* g++.dg/expr/lval3.C: Likewise.
* g++.dg/expr/lval4.C: Likewise.
* g++.old-deja/g++.jason/bool5.C: Likewise.

From-SVN: r240436

8 years ago* configure.ac: Define HAVE_MEMALIGN for newlib.
Jason Merrill [Fri, 23 Sep 2016 14:34:51 +0000 (10:34 -0400)]
* configure.ac: Define HAVE_MEMALIGN for newlib.

From-SVN: r240435

8 years agoProvide location information for terminator characters (PR preprocessor/77672)
David Malcolm [Fri, 23 Sep 2016 14:14:52 +0000 (14:14 +0000)]
Provide location information for terminator characters (PR preprocessor/77672)

substring_loc::get_location currently fails for the final terminator
character in a STRING_CST from the C frontend, so that format_warning_va
falls back to using the location of the string as a whole.

This patch tweaks things [1] so that we use the final closing quote
as the location of the terminator character, as requested in
PR preprocessor/77672.

[1] specifically, cpp_interpret_string_1.

gcc/ChangeLog:
PR preprocessor/77672
* input.c (selftest::test_lexer_string_locations_simple): Update
test to expect location information of the terminator character
at the location of the final closing quote.
(selftest::test_lexer_string_locations_hex): Likewise.
(selftest::test_lexer_string_locations_oct): Likewise.
(selftest::test_lexer_string_locations_letter_escape_1): Likewise.
(selftest::test_lexer_string_locations_letter_escape_2): Likewise.
(selftest::test_lexer_string_locations_ucn4): Likewise.
(selftest::test_lexer_string_locations_ucn8): Likewise.
(selftest::test_lexer_string_locations_u8): Likewise.
(selftest::test_lexer_string_locations_utf8_source): Likewise.
(selftest::test_lexer_string_locations_concatenation_1): Likewise.
(selftest::test_lexer_string_locations_concatenation_2): Likewise.
(selftest::test_lexer_string_locations_concatenation_3): Likewise.
(selftest::test_lexer_string_locations_macro): Likewise.
(selftest::test_lexer_string_locations_long_line): Likewise.

gcc/testsuite/ChangeLog:
PR preprocessor/77672
* gcc.dg/plugin/diagnostic-test-string-literals-1.c
(test_terminator_location): New function.

libcpp/ChangeLog:
PR preprocessor/77672
* charset.c (cpp_interpret_string_1): Add a source_range for the
NUL-terminator, using the location of the trailing quote of the
final string.

From-SVN: r240434

8 years agoReally commit testcase intended for r240230.
Fritz Reese [Fri, 23 Sep 2016 13:31:37 +0000 (13:31 +0000)]
Really commit testcase intended for r240230.

2016-09-23  Fritz Reese  <fritzoreese@gmail.com>

Really commit testcase intended for r240230.

* gcc/testsuite/gfortran.dg/dec_structure_15.f90: Really commit.

From-SVN: r240433

8 years agotree-ssa-sccvn.c (visit_reference_op_call): Value number virtual definition to virtua...
Richard Biener [Fri, 23 Sep 2016 12:39:05 +0000 (12:39 +0000)]
tree-ssa-sccvn.c (visit_reference_op_call): Value number virtual definition to virtual use if...

2016-09-23  Richard Biener  <rguenther@suse.de>

* tree-ssa-sccvn.c (visit_reference_op_call): Value number
virtual definition to virtual use if the call devirtualizes
to a const or pure function.
(visit_use): Also visit calls we can devirtualize to a
const or pure function.

* gcc.dg/tree-ssa/ssa-fre-56.c: New testcase.

From-SVN: r240431

8 years agore PR tree-optimization/77697 (suspicious code in tree-ssa-forwprop.c)
Richard Biener [Fri, 23 Sep 2016 12:37:22 +0000 (12:37 +0000)]
re PR tree-optimization/77697 (suspicious code in tree-ssa-forwprop.c)

2016-09-23  Richard Biener  <rguenther@suse.de>

PR tree-optimization/77697
* tree-ssa-forwprop.c (defcodefor_name): Remove bogus code,
signal error if we have sth ternary or unhandled.

From-SVN: r240430

8 years agoRevert bogus dg-extract-results.sh change
Rainer Orth [Fri, 23 Sep 2016 11:35:34 +0000 (11:35 +0000)]
Revert bogus dg-extract-results.sh change

* dg-extract-results.sh: Revert bogus change.

From-SVN: r240429

8 years ago[PATCH 17/17][ARM] Add tests for NEON FP16 ACLE intrinsics.
Matthew Wahab [Fri, 23 Sep 2016 10:57:20 +0000 (10:57 +0000)]
[PATCH 17/17][ARM] Add tests for NEON FP16 ACLE intrinsics.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/advsimd-intrinsics/advsimd-intrinsics.exp: Enable
-march=armv8.2-a+fp16 when supported by the hardware.
* gcc.target/aarch64/advsimd-intrinsics/binary_op_float.inc: New.
* gcc.target/aarch64/advsimd-intrinsics/binary_op_no64.inc:
Add F16 tests, enabled if macro HAS_FLOAT16_VARIANT is defined.  Add
semi-colons to a macro invocations.
* gcc.target/aarch64/advsimd-intrinsics/cmp_fp_op.inc: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/cmp_op.inc: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/cmp_zero_op.inc: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vabd.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vabs.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vadd.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcage.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcagt.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcale.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcalt.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vceq.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vceqz_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcge.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vcgez_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcgt.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vcgtz_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcle.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vclez_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vclt.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vcltz_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vcvt.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.  Also fix some white-space.
* gcc.target/aarch64/advsimd-intrinsics/vcvtX.inc: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvta_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtm_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtp_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vfma.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.  Also fix some long lines and white-space.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vfms.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.  Also fix some long lines and white-space.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vmax.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vmaxnm_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vmin.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vminnm_1.c: New.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vmul.c: Add F16
tests, enabled if macro __ARM_FEATURE_FP16_VECTOR_ARITHMETIC is
defined.
* gcc.target/aarch64/advsimd-intrinsics/vmul_lane.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vmul_n.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vneg.c:
Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vpXXX.inc: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vpadd.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vpmax.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vpmin.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrecpe.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrecps.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrnd.c:
Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vrndX.inc: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrnda.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrndm.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrndn.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrndp.c:
Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vrndx.c:
Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vrsqrte.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vrsqrts.c: Likewise.
* gcc.target/gcc.target/aarch64/advsimd-intrinsics/vsub.c:
Likewise.

From-SVN: r240427

8 years ago[PATCH 16/17][ARM] Add tests for VFP FP16 ACLE instrinsics.
Jiong Wang [Fri, 23 Sep 2016 10:54:14 +0000 (10:54 +0000)]
[PATCH 16/17][ARM] Add tests for VFP FP16 ACLE instrinsics.

testsuite/
2016-09-23  Jiong Wang  <jiong.wang@arm.com>
    Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/aarch64/advsimd-intrinsics/binary_scalar_op.inc: New.
* gcc.target/aarch64/advsimd-intrinsics/unary_scalar_op.inc: New.
* gcc.target/aarch64/advsimd-intrinsics/ternary_scalar_op.inc: New.
* gcc.target/aarch64/advsimd-intrinsics/vabsh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vaddh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtah_s32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtah_u32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_f16_s32_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_f16_u32_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_n_f16_s32_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_n_f16_u32_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_n_s32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_n_u32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_s32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvth_u32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtmh_s32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtmh_u32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtnh_s32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtnh_u32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtph_s32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vcvtph_u32_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vdivh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vfmah_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vfmsh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vmaxnmh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vminnmh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vmulh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vnegh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndah_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndih_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndmh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndnh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndph_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vrndxh_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vsqrth_f16_1.c: New.
* gcc.target/aarch64/advsimd-intrinsics/vsubh_f16_1.c: New.

Co-Authored-By: Matthew Wahab <matthew.wahab@arm.com>
From-SVN: r240426

8 years ago[PATCH 15/17][ARM] Add tests for ARMv8.2-A FP16 support.
Matthew Wahab [Fri, 23 Sep 2016 10:48:47 +0000 (10:48 +0000)]
[PATCH 15/17][ARM] Add tests for ARMv8.2-A FP16 support.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/arm/armv8_2-fp16-neon-1.c: New.
* gcc.target/arm/armv8_2-fp16-scalar-1.c: New.
* gcc.target/arm/armv8_2-fp16-scalar-2.c: New.
* gcc.target/arm/attr-fp16-arith-1.c: Add a test of intrinsics
support.

From-SVN: r240425

8 years ago[PATCH 14/17][ARM] Add NEON FP16 instrinsics.
Matthew Wahab [Fri, 23 Sep 2016 10:46:26 +0000 (10:46 +0000)]
[PATCH 14/17][ARM] Add NEON FP16 instrinsics.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm_neon.h (vabd_f16): New.
(vabdq_f16): New.
(vabs_f16): New.
(vabsq_f16): New.
(vadd_f16): New.
(vaddq_f16): New.
(vcage_f16): New.
(vcageq_f16): New.
(vcagt_f16): New.
(vcagtq_f16): New.
(vcale_f16): New.
(vcaleq_f16): New.
(vcalt_f16): New.
(vcaltq_f16): New.
(vceq_f16): New.
(vceqq_f16): New.
(vceqz_f16): New.
(vceqzq_f16): New.
(vcge_f16): New.
(vcgeq_f16): New.
(vcgez_f16): New.
(vcgezq_f16): New.
(vcgt_f16): New.
(vcgtq_f16): New.
(vcgtz_f16): New.
(vcgtzq_f16): New.
(vcle_f16): New.
(vcleq_f16): New.
(vclez_f16): New.
(vclezq_f16): New.
(vclt_f16): New.
(vcltq_f16): New.
(vcltz_f16): New.
(vcltzq_f16): New.
(vcvt_f16_s16): New.
(vcvt_f16_u16): New.
(vcvt_s16_f16): New.
(vcvt_u16_f16): New.
(vcvtq_f16_s16): New.
(vcvtq_f16_u16): New.
(vcvtq_s16_f16): New.
(vcvtq_u16_f16): New.
(vcvta_s16_f16): New.
(vcvta_u16_f16): New.
(vcvtaq_s16_f16): New.
(vcvtaq_u16_f16): New.
(vcvtm_s16_f16): New.
(vcvtm_u16_f16): New.
(vcvtmq_s16_f16): New.
(vcvtmq_u16_f16): New.
(vcvtn_s16_f16): New.
(vcvtn_u16_f16): New.
(vcvtnq_s16_f16): New.
(vcvtnq_u16_f16): New.
(vcvtp_s16_f16): New.
(vcvtp_u16_f16): New.
(vcvtpq_s16_f16): New.
(vcvtpq_u16_f16): New.
(vcvt_n_f16_s16): New.
(vcvt_n_f16_u16): New.
(vcvtq_n_f16_s16): New.
(vcvtq_n_f16_u16): New.
(vcvt_n_s16_f16): New.
(vcvt_n_u16_f16): New.
(vcvtq_n_s16_f16): New.
(vcvtq_n_u16_f16): New.
(vfma_f16): New.
(vfmaq_f16): New.
(vfms_f16): New.
(vfmsq_f16): New.
(vmax_f16): New.
(vmaxq_f16): New.
(vmaxnm_f16): New.
(vmaxnmq_f16): New.
(vmin_f16): New.
(vminq_f16): New.
(vminnm_f16): New.
(vminnmq_f16): New.
(vmul_f16): New.
(vmul_lane_f16): New.
(vmul_n_f16): New.
(vmulq_f16): New.
(vmulq_lane_f16): New.
(vmulq_n_f16): New.
(vneg_f16): New.
(vnegq_f16): New.
(vpadd_f16): New.
(vpmax_f16): New.
(vpmin_f16): New.
(vrecpe_f16): New.
(vrecpeq_f16): New.
(vrnd_f16): New.
(vrndq_f16): New.
(vrnda_f16): New.
(vrndaq_f16): New.
(vrndm_f16): New.
(vrndmq_f16): New.
(vrndn_f16): New.
(vrndnq_f16): New.
(vrndp_f16): New.
(vrndpq_f16): New.
(vrndx_f16): New.
(vrndxq_f16): New.
(vrsqrte_f16): New.
(vrsqrteq_f16): New.
(vrecps_f16): New.
(vrecpsq_f16): New.
(vrsqrts_f16): New.
(vrsqrtsq_f16): New.
(vsub_f16): New.
(vsubq_f16): New.

From-SVN: r240424

8 years ago[PATCH 13/17][ARM] Add VFP FP16 instrinsics.
Matthew Wahab [Fri, 23 Sep 2016 10:41:04 +0000 (10:41 +0000)]
[PATCH 13/17][ARM] Add VFP FP16 instrinsics.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config.gcc (extra_headers): Add arm_fp16.h
* config/arm/arm_fp16.h: New.
* config/arm/arm_neon.h: Include "arm_fp16.h".

From-SVN: r240423

8 years ago[PATCH 12/17][ARM] Add builtins for NEON FP16 intrinsics.
Matthew Wahab [Fri, 23 Sep 2016 10:34:57 +0000 (10:34 +0000)]
[PATCH 12/17][ARM] Add builtins for NEON FP16 intrinsics.

2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm_neon_builtins.def (vadd): New (v8hf, v4hf
variants).
(vmulf): New (v8hf, v4hf variants).
(vfma): New (v8hf, v4hf variants).
(vfms): New (v8hf, v4hf variants).
(vsub): New (v8hf, v4hf variants).
(vcage): New (v8hf, v4hf variants).
(vcagt): New (v8hf, v4hf variants).
(vcale): New (v8hf, v4hf variants).
(vcalt): New (v8hf, v4hf variants).
(vceq): New (v8hf, v4hf variants).
(vcgt): New (v8hf, v4hf variants).
(vcge): New (v8hf, v4hf variants).
(vcle): New (v8hf, v4hf variants).
(vclt): New (v8hf, v4hf variants).
(vceqz): New (v8hf, v4hf variants).
(vcgez): New (v8hf, v4hf variants).
(vcgtz): New (v8hf, v4hf variants).
(vcltz): New (v8hf, v4hf variants).
(vclez): New (v8hf, v4hf variants).
(vabd): New (v8hf, v4hf variants).
(vmaxf): New (v8hf, v4hf variants).
(vmaxnm): New (v8hf, v4hf variants).
(vminf): New (v8hf, v4hf variants).
(vminnm): New (v8hf, v4hf variants).
(vpmaxf): New (v4hf variant).
(vpminf): New (v4hf variant).
(vpadd): New (v4hf variant).
(vrecps): New (v8hf, v4hf variants).
(vrsqrts): New (v8hf, v4hf variants).
(vabs): New (v8hf, v4hf variants).
(vneg): New (v8hf, v4hf variants).
(vrecpe): New (v8hf, v4hf variants).
(vrnd): New (v8hf, v4hf variants).
(vrnda): New (v8hf, v4hf variants).
(vrndm): New (v8hf, v4hf variants).
(vrndn): New (v8hf, v4hf variants).
(vrndp): New (v8hf, v4hf variants).
(vrndx): New (v8hf, v4hf variants).
(vrsqrte): New (v8hf, v4hf variants).
(vmul_lane): Add v4hf and v8hf variants.
(vmul_n): Add v4hf and v8hf variants.
(vext): New (v8hf, v4hf variants).
(vcvts): New (v8hi, v4hi variants).
(vcvts): New (v8hf, v4hf variants).
(vcvtu): New (v8hi, v4hi variants).
(vcvtu): New (v8hf, v4hf variants).
(vcvts_n): New (v8hf, v4hf variants).
(vcvtu_n): New (v8hi, v4hi variants).
(vcvts_n): New (v8hi, v4hi variants).
(vcvtu_n): New (v8hf, v4hf variants).
(vbsl): New (v8hf, v4hf variants).
(vcvtas): New (v8hf, v4hf variants).
(vcvtau): New (v8hf, v4hf variants).
(vcvtms): New (v8hf, v4hf variants).
(vcvtmu): New (v8hf, v4hf variants).
(vcvtns): New (v8hf, v4hf variants).
(vcvtnu): New (v8hf, v4hf variants).
(vcvtps): New (v8hf, v4hf variants).
(vcvtpu): New (v8hf, v4hf variants).

From-SVN: r240422

8 years ago[PATCH 11/17][ARM] Add builtins for VFP FP16 intrinsics.
Matthew Wahab [Fri, 23 Sep 2016 10:28:44 +0000 (10:28 +0000)]
[PATCH 11/17][ARM] Add builtins for VFP FP16 intrinsics.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm-builtins.c (hf_UP): New.
(si_UP): New.
(vfp_builtin_data): New.  Update comment.
(enum arm_builtins): Include "arm_vfp_builtins.def".
(ARM_BUILTIN_VFP_PATTERN_START): New.
(arm_init_vfp_builtins): New.
(arm_init_builtins): Add arm_init_vfp_builtins.
(arm_expand_vfp_builtin): New.
(arm_expand_builtins): Update for arm_expand_vfp_builtin.  Fix
long line.
* config/arm/arm_vfp_builtins.def: New file.
* config/arm/t-arm (arm.o): Add arm_vfp_builtins.def.
(arm-builtins.o): Likewise.

From-SVN: r240421

8 years agoDrop TREE_OVERFLOW
Kugan Vivekanandarajah [Fri, 23 Sep 2016 10:25:09 +0000 (10:25 +0000)]
Drop TREE_OVERFLOW

gcc/ChangeLog:

2016-09-23  Kugan Vivekanandarajah  <kuganv@linaro.org>

PR ipa/77677
* ipa-cp.c (propagate_vr_accross_jump_function): Drop TREE_OVERFLOW
from constant while creating value range.

gcc/testsuite/ChangeLog:

2016-09-23  Kugan Vivekanandarajah  <kuganv@linaro.org>

PR ipa/77677
* gcc.dg/torture/pr77677.c: New test.

From-SVN: r240420

8 years agotrans-intrinsic.c (gfc_conv_intrinsic_caf_get): Use the old caf- interface where...
Andre Vehreschild [Fri, 23 Sep 2016 10:17:22 +0000 (12:17 +0200)]
trans-intrinsic.c (gfc_conv_intrinsic_caf_get): Use the old caf- interface where possible.

gcc/fortran/ChangeLog:

2016-09-23  Andre Vehreschild  <vehre@gcc.gnu.org>

* trans-intrinsic.c (gfc_conv_intrinsic_caf_get): Use the old caf-
interface where possible.

gcc/testsuite/ChangeLog:

2016-09-23  Andre Vehreschild  <vehre@gcc.gnu.org>

* gfortran.dg/coarray_lib_comm_1.f90: Using the old caf-interface
here now.

From-SVN: r240419

8 years ago[PATCH][IRA]Initialize ira_use_lra_p early by moving the initialization into
Renlin Li [Fri, 23 Sep 2016 10:16:22 +0000 (10:16 +0000)]
[PATCH][IRA]Initialize ira_use_lra_p early by moving the initialization into
ira_init_once ().

ira_use_lra_p previously will be used unintialized in backend_init_target ().

gcc/

2016-09-23  Renlin Li  <renlin.li@arm.com>

* ira.c (ira): Move ira_use_lra_p initialization code to ...
(ira_init_once): Here.

From-SVN: r240418

8 years agohooks.h (hook_uint_uintp_false): Rename to...
Uros Bizjak [Fri, 23 Sep 2016 10:05:29 +0000 (12:05 +0200)]
hooks.h (hook_uint_uintp_false): Rename to...

* hooks.h (hook_uint_uintp_false): Rename to...
(hook_bool_uint_uintp_false): ... this.
* hooks.c (hook_uint_uintp_false): Rename to...
(hook_bool_uint_uintp_false): ... this.
* target.def (elf_flags_numeric): Use hook_bool_uint_uintp_false
instead of hook_uint_uintp_false.

Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
From-SVN: r240417

8 years ago[PATCH 10/17][ARM] Refactor support code for NEON builtins.
Matthew Wahab [Fri, 23 Sep 2016 09:59:55 +0000 (09:59 +0000)]
[PATCH 10/17][ARM] Refactor support code for NEON builtins.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm-builtins.c (arm_init_neon_builtin): New.
(arm_init_builtins): Move body of a loop to the standalone
function arm_init_neon_builtin.
(arm_expand_neon_builtin_1): New.  Update comment.  Function body
moved from arm_neon_builtin with some white-space fixes.
(arm_expand_neon_builtin): Move code into the standalone function
arm_expand_neon_builtin_1.

From-SVN: r240416

8 years ago[PATCH 9/17][ARM] Add NEON FP16 arithmetic instructions.
Matthew Wahab [Fri, 23 Sep 2016 09:54:44 +0000 (09:54 +0000)]
[PATCH 9/17][ARM] Add NEON FP16 arithmetic instructions.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/iterators.md (VCVTHI): New.
(NEON_VCMP): Add UNSPEC_VCLT and UNSPEC_VCLE.  Fix a long line.
(NEON_VAGLTE): New.
(VFM_LANE_AS): New.
(VH_CVTTO): New.
(V_reg): Add HF, V4HF and V8HF.  Fix white-space.
(V_HALF): Add V4HF.  Fix white-space.
(V_if_elem): Add HF, V4HF and V8HF.  Fix white-space.
(V_s_elem): Likewise.
(V_sz_elem): Fix white-space.
(V_elem_ch): Likewise.
(VH_elem_ch): New.
(scalar_mul_constraint): Add V8HF and V4HF.
(Is_float_mode): Fix white-space.
(Is_d_reg): Add V4HF and V8HF.  Fix white-space.
(q): Add HF.  Fix white-space.
(float_sup): New.
(float_SUP): New.
(cmp_op_unsp): Add UNSPEC_VCALE and UNSPEC_VCALT.
(neon_vfm_lane_as): New.
* config/arm/neon.md (add<mode>3_fp16): New.
(sub<mode>3_fp16): New.
(mul<mode>3add<mode>_neon): New.
(fma<VH:mode>4_intrinsic): New.
(fmsub<VCVTF:mode>4_intrinsic): Fix white-space.
(fmsub<VH:mode>4_intrinsic): New.
(<absneg_str><mode>2): New.
(neon_v<absneg_str><mode>): New.
(neon_v<fp16_rnd_str><mode>): New.
(neon_vrsqrte<mode>): New.
(neon_vpaddv4hf): New.
(neon_vadd<mode>): New.
(neon_vsub<mode>): New.
(neon_vmulf<mode>): New.
(neon_vfma<VH:mode>): New.
(neon_vfms<VH:mode>): New.
(neon_vc<cmp_op><mode>): New.
(neon_vc<cmp_op><mode>_fp16insn): New
(neon_vc<cmp_op_unsp><mode>_fp16insn_unspec): New.
(neon_vca<cmp_op><mode>): New.
(neon_vca<cmp_op><mode>_fp16insn): New.
(neon_vca<cmp_op_unsp><mode>_fp16insn_unspec): New.
(neon_vc<cmp_op>z<mode>): New.
(neon_vabd<mode>): New.
(neon_v<maxmin>f<mode>): New.
(neon_vp<maxmin>fv4hf: New.
(neon_<fmaxmin_op><mode>): New.
(neon_vrecps<mode>): New.
(neon_vrsqrts<mode>): New.
(neon_vrecpe<mode>): New (VH variant).
(neon_vdup_lane<mode>_internal): New.
(neon_vdup_lane<mode>): New.
(neon_vcvt<sup><mode>): New (VCVTHI variant).
(neon_vcvt<sup><mode>): New (VH variant).
(neon_vcvt<sup>_n<mode>): New (VH variant).
(neon_vcvt<sup>_n<mode>): New (VCVTHI variant).
(neon_vcvt<vcvth_op><sup><mode>): New.
(neon_vmul_lane<mode>): New.
(neon_vmul_n<mode>): New.
* config/arm/unspecs.md (UNSPEC_VCALE): New
(UNSPEC_VCALT): New.
(UNSPEC_VFMA_LANE): New.
(UNSPECS_VFMS_LANE): New.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/arm/armv8_2-fp16-arith-1.c: Use arm_v8_2a_fp16_neon
options.  Add tests for float16x4_t and float16x8_t.

From-SVN: r240415

8 years agoS/390: Improved risbg usage.
Dominik Vogt [Fri, 23 Sep 2016 09:53:29 +0000 (09:53 +0000)]
S/390: Improved risbg usage.

gcc/ChangeLog:

2016-09-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>

* config/s390/s390.md ("*extzv<mode>_zEC12", "*extzv<mode>_z10")
("*extzv<mode><clobbercc_or_nocc>"):
Correct a typo in a comment.
Merged patterns.
("*insv<mode>_zEC12", "*insv<mode>_z10")
("*insv<mode><clobbercc_or_nocc>"): Ditto.
("*insv<mode>_zEC12_appendbitsleft")
("*insv<mode><clobbercc_or_nocc>_appendbitsleft")
("*insv<mode>_z10_appendbitsleft"): Ditto.
("*insv<mode>_zEC12_noshift", "*insv<mode>_z10_noshift")
("*insv<mode><clobbercc_or_nocc>_noshift"): Ditto.
Provide pattern with operands switched.
("*pre_z10_extv<mode>"):
Use new subst patterns.
("*extzvdi<clobbercc_or_nocc>_lshiftrt", "*<risbg_n>_ior_and_sr_ze")
("*extvsidi<clobbercc_or_nocc>", "*<risbg_n>_and_subregdi_rotr")
("*<risbg_n>_and_subregdi_rotl", "*<risbg_n>_di_and_rot")
("*insv_z10_noshift_cc", "*insv_z10_noshift_cconly")
("*<risbg_n>_<mode>_ior_and_lshiftrt")
("*<risbg_n>_sidi_ior_and_lshiftrt")
("*trunc_sidi_and_subreg_lshrt<clobbercc_or_nocc>"):
New patterns.
("*extzv_<mode>_sll", "*extzv_<mode>_srl")
("*extzv_<mode>_srl<clobbercc_or_nocc>")
("*extzv_<mode>_sll<clobbercc_or_nocc>"): Renamed patterns, use risbgn
on zEC12.
("SINT"): New mode_iterator with SI, HI, QI.
* config/s390/subst.md ("clobbercc_or_nocc_subst", "z10_or_zEC12_cond")
("clobbercc_or_nocc", "risbg_n"): New constructs for risbg pattern
duplication.

gcc/testsuite/ChangeLog:

2016-09-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>

* gcc.target/s390/risbg-ll-1.c: Ported risbg tests from llvm.
* gcc.target/s390/risbg-ll-2.c: Ditto.
* gcc.target/s390/risbg-ll-3.c: Ditto.

From-SVN: r240414

8 years agoS/390: Enable wraparound in s390_contiguous_bitmask_p.
Dominik Vogt [Fri, 23 Sep 2016 09:49:58 +0000 (09:49 +0000)]
S/390: Enable wraparound in s390_contiguous_bitmask_p.

gcc/ChangeLog:

2016-09-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>

* config/s390/predicates.md ("contiguous_bitmask_operand"): Adapt to new
interface of s390_contiguous_bitmask_p.
("contiguous_bitmask_nowrap_operand"): New predicate.
* ("*anddi3_cc", "*anddi3_cconly", "*anddi3"): Replace NxxDq with NxxDw.
* config/s390/constraints.md ("NxxDw", "NxxSq"): Adapt to new interface
of s390_contiguous_bitmask_p.
* ("NxxDw"): Rename NxxDq constraint to NxxDw.
("NxxSw"): New constraint.
* config/s390/s390.md ("*andsi3_zarch"): Enable bitmask wraparound.
* config/s390/s390-protos.h (s390_contiguous_bitmask_p): Updated
interface.
(s390_contiguous_bitmask_nowrap_p): Export.
* config/s390/s390.c (s390_contiguous_bitmask_nowrap_p): New name of
former s390_contiguous_bitmask_p.
(s390_contiguous_bitmask_p): Use s390_contiguous_bitmask_nowrap_p to
detect contiguous bit ranges with wraparound.  Change signature to
return START and END position instead of POS and LENGTH.
(s390_contiguous_bitmask_vector_p): Remove extra code for continous bit
ranges with wraparound.
(s390_extzv_shift_ok): Use s390_contiguous_bitmask_nowrap_p.
(s390_contiguous_bitmask_vector_p,s390_extzv_shift_ok,print_operand):
Adapt to new signature of s390_contiguous_bitmask_p.

From-SVN: r240413

8 years agotree-vect-loop-manip.c (create_intersect_range_checks_index): New.
Bin Cheng [Fri, 23 Sep 2016 09:47:52 +0000 (09:47 +0000)]
tree-vect-loop-manip.c (create_intersect_range_checks_index): New.

* tree-vect-loop-manip.c (create_intersect_range_checks_index): New.
(create_intersect_range_checks): New.
(vect_create_cond_for_alias_checks): Call above function.

From-SVN: r240412

8 years ago[PATCH 8/17][ARM] Add VFP FP16 arithmetic instructions.
Matthew Wahab [Fri, 23 Sep 2016 09:46:26 +0000 (09:46 +0000)]
[PATCH 8/17][ARM] Add VFP FP16 arithmetic instructions.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/iterators.md (Code iterators): Fix some white-space
in the comments.
(GLTE): New.
(ABSNEG): New
(FCVT): Moved from vfp.md.
(VCVT_HF_US_N): New.
(VCVT_SI_US_N): New.
(VCVT_HF_US): New.
(VCVTH_US): New.
(FP16_RND): New.
(absneg_str): New.
(FCVTI32typename): Moved from vfp.md.
(sup): Add UNSPEC_VCVTA_S, UNSPEC_VCVTA_U, UNSPEC_VCVTM_S,
UNSPEC_VCVTM_U, UNSPEC_VCVTN_S, UNSPEC_VCVTN_U, UNSPEC_VCVTP_S,
UNSPEC_VCVTP_U, UNSPEC_VCVT_HF_S_N, UNSPEC_VCVT_HF_U_N,
UNSPEC_VCVT_SI_S_N, UNSPEC_VCVT_SI_U_N,  UNSPEC_VCVTH_S_N,
UNSPEC_VCVTH_U_N, UNSPEC_VCVTH_S and UNSPEC_VCVTH_U.
(vcvth_op): New.
(fp16_rnd_str): New.
(fp16_rnd_insn): New.
* config/arm/unspecs.md (UNSPEC_VCVT_HF_S_N): New.
(UNSPEC_VCVT_HF_U_N): New.
(UNSPEC_VCVT_SI_S_N): New.
(UNSPEC_VCVT_SI_U_N): New.
(UNSPEC_VCVTH_S): New.
(UNSPEC_VCVTH_U): New.
(UNSPEC_VCVTA_S): New.
(UNSPEC_VCVTA_U): New.
(UNSPEC_VCVTM_S): New.
(UNSPEC_VCVTM_U): New.
(UNSPEC_VCVTN_S): New.
(UNSPEC_VCVTN_U): New.
(UNSPEC_VCVTP_S): New.
(UNSPEC_VCVTP_U): New.
(UNSPEC_VCVTP_S): New.
(UNSPEC_VCVTP_U): New.
(UNSPEC_VRND): New.
(UNSPEC_VRNDA): New.
(UNSPEC_VRNDI): New.
(UNSPEC_VRNDM): New.
(UNSPEC_VRNDN): New.
(UNSPEC_VRNDP): New.
(UNSPEC_VRNDX): New.
* config/arm/vfp.md (<absneg_str>hf2): New.
(neon_vabshf): New.
(neon_v<fp16_rnd_str>hf): New.
(neon_vrndihf): New.
(addhf3): New.
(subhf3): New.
(divhf3): New.
(mulhf3): New.
(*mulsf3neghf_vfp): New.
(*negmulhf3_vfp): New.
(*mulsf3addhf_vfp): New.
(*mulhf3subhf_vfp): New.
(*mulhf3neghfaddhf_vfp): New.
(*mulhf3neghfsubhf_vfp): New.
(fmahf4): New.
(neon_vfmahf): New.
(fmsubhf4_fp16): New.
(neon_vfmshf): New.
(*fnmsubhf4): New.
(*fnmaddhf4): New.
(neon_vsqrthf): New.
(neon_vrsqrtshf): New.
(FCVT): Move to iterators.md.
(FCVTI32typename): Likewise.
(neon_vcvth<sup>hf): New.
(neon_vcvth<sup>si): New.
(neon_vcvth<sup>_nhf_unspec): New.
(neon_vcvth<sup>_nhf): New.
(neon_vcvth<sup>_nsi_unspec): New.
(neon_vcvth<sup>_nsi): New.
(neon_vcvt<vcvth_op>h<sup>si): New.
(neon_<fmaxmin_op>hf): New.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/arm/armv8_2-fp16-arith-1.c: New.
* gcc.target/arm/armv8_2-fp16-conv-1.c: New.

From-SVN: r240411

8 years agoAdd missing ChangeLog from r240375
Tamar Christina [Fri, 23 Sep 2016 09:45:04 +0000 (09:45 +0000)]
Add missing ChangeLog from r240375

From-SVN: r240410

8 years agoS/390: Mode attrs "bitoff[_plus]" simplify risbg instructions.
Dominik Vogt [Fri, 23 Sep 2016 09:44:15 +0000 (09:44 +0000)]
S/390: Mode attrs "bitoff[_plus]" simplify risbg instructions.

Add a new mode attribute to simplify some instruction patterns.

gcc/ChangeLog:

2016-09-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>

* config/s390/s390.md (bitoff, bitoff_plus): Neq mode attributes.
("*extzv<mode>_zEC12", "*insv<mode>_zEC12", "*insv<mode>_z10")
("*insv<mode>_zEC12_appendbitsleft")
("*insv<mode>_z10_appendbitsleft", "*r<noxa>sbg_<mode>_sll")
("*r<noxa>sbg_<mode>_srl"): Use new attributes.

gcc/testsuite/ChangeLog:

2016-09-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>

* gcc.target/s390/md/rXsbg_mode_sXl.c: Adapt expected assembly
output to the simplified instructions.

From-SVN: r240409

8 years agoipa-cp.c (ipcp_store_vr_results): Avoid static local var zero.
Jakub Jelinek [Fri, 23 Sep 2016 09:43:09 +0000 (11:43 +0200)]
ipa-cp.c (ipcp_store_vr_results): Avoid static local var zero.

* ipa-cp.c (ipcp_store_vr_results): Avoid static local
var zero.
* sreal.h (sreal::min, sreal::max): Avoid static local vars,
construct values without normalization.
* tree-ssa-sccvn.c (vn_reference_lookup_3): Don't initialize
static local lhs_ops to vNULL.
cp/
* name-lookup.c (store_bindings, store_class_bindings): Don't
initialize static local bindings_need_stored to vNULL.

From-SVN: r240408

8 years ago[PATCH 7/17][ARM] Add FP16 data movement instructions.
Matthew Wahab [Fri, 23 Sep 2016 09:35:22 +0000 (09:35 +0000)]
[PATCH 7/17][ARM] Add FP16 data movement instructions.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>
    Jiong Wang <jiong.wang@arm.com>

* config/arm/arm.c (coproc_secondary_reload_class): Make HFmode
available when FP16 instructions are available.
(output_move_vfp): Add support for 16-bit data moves.
(arm_validize_comparison): Fix some white-space.  Support HFmode
by conversion to SFmode.
* config/arm/arm.md (truncdfhf2): Fix a comment.
(extendhfdf2): Likewise.
(cstorehf4): New.
(movsicc): Fix some white-space.
(movhfcc): New.
(movsfcc): Fix some white-space.
(*cmovhf): New.
* config/arm/vfp.md (*arm_movhi_vfp): Disable when VFP FP16
instructions are available.
(*thumb2_movhi_vfp): Likewise.
(*arm_movhi_fp16): New.
(*thumb2_movhi_fp16): New.
(*movhf_vfp_fp16): New.
(*movhf_vfp_neon): Disable when VFP FP16 instructions are
available.
(*movhf_vfp): Likewise.
(extendhfsf2): Enable when VFP FP16 instructions are available.
(truncsfhf2):  Enable when VFP FP16 instructions are available.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/arm/armv8_2_fp16-move-1.c: New.
* gcc.target/arm/fp16-aapcs-1.c: Update expected output.

Co-Authored-By: Jiong Wang <jiong.wang@arm.com>
From-SVN: r240407

8 years agoFix typos: adress -> address
Martin Liska [Fri, 23 Sep 2016 09:32:15 +0000 (11:32 +0200)]
Fix typos: adress -> address

* config/s390/vx-builtins.md: Replace 'adress' with 'address'.

From-SVN: r240406

8 years agogcc-dg.exp (process-message): Support relative line number notation - .+4 or .-1...
Jakub Jelinek [Fri, 23 Sep 2016 09:23:52 +0000 (11:23 +0200)]
gcc-dg.exp (process-message): Support relative line number notation - .+4 or .-1 etc.

* lib/gcc-dg.exp (process-message): Support relative line number
notation - .+4 or .-1 etc.
* gcc.dg/dg-test-1.c: New test.

From-SVN: r240405

8 years ago[PATCH 6/17][ARM] Add data processing intrinsics for float16_t.
Matthew Wahab [Fri, 23 Sep 2016 09:23:01 +0000 (09:23 +0000)]
[PATCH 6/17][ARM] Add data processing intrinsics for float16_t.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm.c (arm_evpc_neon_vuzp): Add support for V8HF and
V4HF modes.
(arm_evpc_neon_vtrn): Likewise.
(arm_evpc_neon_vrev): Likewise.
(arm_evpc_neon_vext): Likewise.
* config/arm/arm_neon.h (vbsl_f16): New.
(vbslq_f16): New.
(vdup_n_f16): New.
(vdupq_n_f16): New.
(vdup_lane_f16): New.
(vdupq_lane_f16): New.
(vext_f16): New.
(vextq_f16): New.
(vmov_n_f16): New.
(vmovq_n_f16): New.
(vrev64_f16): New.
(vrev64q_f16): New.
(vtrn_f16): New.
(vtrnq_f16): New.
(vuzp_f16): New.
(vuzpq_f16): New.
(vzip_f16): New.
(vzipq_f16): New.
* config/arm/arm_neon_buillins.def (vdup_n): New (v8hf, v4hf variants).
(vdup_lane): New (v8hf, v4hf variants).
(vext): New (v8hf, v4hf variants).
(vbsl): New (v8hf, v4hf variants).
* config/arm/iterators.md (VDQWH): New.
(VH): New.
(V_double_vector_mode): Add V8HF and V4HF.  Fix white-space.
(Scalar_mul_8_16): Fix white-space.
(Is_d_reg): Add V4HF and V8HF.
* config/arm/neon.md (neon_vdup_lane<mode>_internal): New.
(neon_vdup_lane<mode>): New.
(neon_vtrn<mode>_internal): Replace VDQW with VDQWH.
(*neon_vtrn<mode>_insn): Likewise.
(neon_vzip<mode>_internal): Likewise. Also fix white-space.
(*neon_vzip<mode>_insn): Likewise
(neon_vuzp<mode>_internal): Likewise.
(*neon_vuzp<mode>_insn): Likewise
* config/arm/vec-common.md (vec_perm_const<mode>): New.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/aarch64/advsimd-intrinsics/arm-neon-ref.h
(FP16_SUPPORTED): New
(expected-hfloat-16x4): Make conditional on __fp16 support.
(expected-hfloat-16x8): Likewise.
(vdup_n_f16): Disable for non-AArch64 targets.
* gcc.target/aarch64/advsimd-intrinsics/vbsl.c: Add __fp16 tests,
conditional on FP16_SUPPORTED.
* gcc.target/aarch64/advsimd-intrinsics/vdup-vmov.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vdup_lane.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vext.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vrev.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vshuffle.inc: Add support
for testing __fp16.
* gcc.target/aarch64/advsimd-intrinsics/vtrn.c: Add __fp16 tests,
conditional on FP16_SUPPORTED.
* gcc.target/aarch64/advsimd-intrinsics/vuzp.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vzip.c: Likewise.

From-SVN: r240404

8 years ago[PATCH 5/17][ARM] Enable HI mode moves for floating point values.
Matthew Wahab [Fri, 23 Sep 2016 09:15:24 +0000 (09:15 +0000)]
[PATCH 5/17][ARM] Enable HI mode moves for floating point values.

gcc/
2016-09-23  Jiong Wang  <jiong.wang@arm.com>
    Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm.c (output_move_vfp): Weaken assert to allow
HImode.
(arm_hard_regno_mode_ok): Allow HImode values in VFP registers.
* config/arm/arm.md (*movhi_bytes): Disable when VFP registers are
available.  Also fix some white-space.
* config/arm/vfp.md (*arm_movhi_vfp): New.
(*thumb2_movhi_vfp): New.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/arm/short-vfp-1.c: New.

From-SVN: r240403

8 years ago[PATCH 4/17][ARM] Define feature macros for FP16.
Matthew Wahab [Fri, 23 Sep 2016 09:09:28 +0000 (09:09 +0000)]
[PATCH 4/17][ARM] Define feature macros for FP16.

2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm-c.c (arm_cpu_builtins): Define
"__ARM_FEATURE_FP16_SCALAR_ARITHMETIC" and
"__ARM_FEATURE_FP16_VECTOR_ARITHMETIC".

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* gcc.target/arm/attr-fp16-arith-1.c: New.

From-SVN: r240402

8 years ago[PATCH 3/17][Testsuite] Add ARM support for ARMv8.2-A with FP16 arithmetic instructions.
Matthew Wahab [Fri, 23 Sep 2016 09:00:34 +0000 (09:00 +0000)]
[PATCH 3/17][Testsuite] Add ARM support for ARMv8.2-A with FP16 arithmetic instructions.

gcc/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* doc/sourcebuild.texi (ARM-specific attributes): Add anchor for
arm_v8_1a_neon_ok.  Add entries for arm_v8_2a_fp16_scalar_ok,
arm_v8_2a_fp16_scalar_hw, arm_v8_2a_fp16_neon_ok and
arm_v8_2a_fp16_neon_hw.
(Add options): Add entries for arm_v8_1a_neon, arm_v8_2a_scalar,
arm_v8_2a_neon.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* lib/target-supports.exp (add_options_for_arm_v8_2a_fp16_scalar):
New.
(add_options_for_arm_v8_2a_fp16_neon): New.
(check_effective_target_arm_arch_v8_2a_ok): Auto-generate.
(add_options_for_arm_arch_v8_2a): Auto-generate.
(check_effective_target_arm_arch_v8_2a_multilib): Auto-generate.
(check_effective_target_arm_v8_2a_fp16_scalar_ok_nocache): New.
(check_effective_target_arm_v8_2a_fp16_scalar_ok): New.
(check_effective_target_arm_v8_2a_fp16_neon_ok_nocache): New.
(check_effective_target_arm_v8_2a_fp16_neon_ok): New.
(check_effective_target_arm_v8_2a_fp16_scalar_hw): New.
(check_effective_target_arm_v8_2a_fp16_neon_hw): New.

From-SVN: r240401

8 years ago[PATCH 2/17][Testsuite] Add a selector for ARM FP16 alternative format support.
Matthew Wahab [Fri, 23 Sep 2016 08:52:55 +0000 (08:52 +0000)]
[PATCH 2/17][Testsuite] Add a selector for ARM FP16 alternative format support.

2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* doc/sourcebuild.texi (ARM-specific attributes): Add entries for
arm_fp16_alternative_ok and arm_fp16_none_ok.

testsuite/
2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* g++.dg/ext/arm-fp16/arm-fp16-ops-3.C: Use
arm_fp16_alternative_ok.
* g++.dg/ext/arm-fp16/arm-fp16-ops-4.C: Likewise.
* gcc.dg/torture/arm-fp16-int-convert-alt.c: Likewise.
* gcc/testsuite/gcc.dg/torture/arm-fp16-ops-3.c: Likewise.
* gcc/testsuite/gcc.dg/torture/arm-fp16-ops-4.c: Likewise.
* gcc.target/arm/fp16-compile-alt-1.c: Likewise.
* gcc.target/arm/fp16-compile-alt-10.c: Likewise.
* gcc.target/arm/fp16-compile-alt-11.c: Likewise.
* gcc.target/arm/fp16-compile-alt-12.c: Likewise.
* gcc.target/arm/fp16-compile-alt-2.c: Likewise.
* gcc.target/arm/fp16-compile-alt-3.c: Likewise.
* gcc.target/arm/fp16-compile-alt-4.c: Likewise.
* gcc.target/arm/fp16-compile-alt-5.c: Likewise.
* gcc.target/arm/fp16-compile-alt-6.c: Likewise.
* gcc.target/arm/fp16-compile-alt-7.c: Likewise.
* gcc.target/arm/fp16-compile-alt-8.c: Likewise.
* gcc.target/arm/fp16-compile-alt-9.c: Likewise.
* gcc.target/arm/fp16-compile-none-1.c: Use arm_fp16_none_ok.
* gcc.target/arm/fp16-compile-none-2.c: Likewise.
* gcc.target/arm/fp16-rounding-alt-1.c: Use
arm_fp16_alternative_ok.
* lib/target-supports.exp
(check_effective_target_arm_fp16_alternative_ok_nocache): New.
(check_effective_target_arm_fp16_alternative_ok): New.
(check_effective_target_arm_fp16_none_ok_nocache): New.
(check_effective_target_arm_fp16_none_ok): New.

From-SVN: r240400

8 years agoFix typo in IPA ICF
Martin Liska [Fri, 23 Sep 2016 08:49:41 +0000 (10:49 +0200)]
Fix typo in IPA ICF

* ipa-icf.c (sem_variable::merge): Replace adress
with address.
* gcc.dg/ipa/pr77653.c: Replace adress
with address.

From-SVN: r240399

8 years ago[PATCH 1/17][ARM] Add ARMv8.2-A command line option and profile.
Matthew Wahab [Fri, 23 Sep 2016 08:45:16 +0000 (08:45 +0000)]
[PATCH 1/17][ARM] Add ARMv8.2-A command line option and profile.

2016-09-23  Matthew Wahab  <matthew.wahab@arm.com>

* config/arm/arm-arches.def ("armv8.1-a"): Add FL_CRC32.
("armv8.2-a"): New.
("armv8.2-a+fp16"): New.
* config/arm/arm-protos.h (FL2_ARCH8_2): New.
(FL2_FP16INST): New.
(FL2_FOR_ARCH8_2A): New.
* config/arm/arm-tables.opt: Regenerate.
* config/arm/arm.c (arm_arch8_2): New.
(arm_fp16_inst): New.
(arm_option_override): Set arm_arch8_2 and arm_fp16_inst.  Check
for incompatible fp16-format settings.
* config/arm/arm.h (TARGET_VFP_FP16INST): New.
(TARGET_NEON_FP16INST): New.
(arm_arch8_2): Declare.
(arm_fp16_inst): Declare.
* config/arm/bpabi.h (BE8_LINK_SPEC): Add entries for
march=armv8.2-a and march=armv8.2-a+fp16.
* config/arm/t-aprofile (Arch Matches): Add entries for armv8.2-a
and armv8.2-a+fp16.
* doc/invoke.texi (ARM Options): Add "-march=armv8.1-a",
"-march=armv8.2-a" and "-march=armv8.2-a+fp16".

From-SVN: r240398

8 years agoRemove fused-madd from documentation
Martin Liska [Fri, 23 Sep 2016 07:58:33 +0000 (09:58 +0200)]
Remove fused-madd from documentation

* doc/extend.texi: Remove fused-madd from i386 target
options.

From-SVN: r240395

8 years agoSupport movbe as a i386 target optimization node
Martin Liska [Fri, 23 Sep 2016 07:58:07 +0000 (09:58 +0200)]
Support movbe as a i386 target optimization node

* gcc.target/i386/movbe-4.c: New test.
* config/i386/i386.c (ix86_valid_target_attribute_inner_p):
Handle movbe.

From-SVN: r240394

8 years agoSupport crc32 as a i386 target optimization node
Martin Liska [Fri, 23 Sep 2016 07:57:07 +0000 (09:57 +0200)]
Support crc32 as a i386 target optimization node

* config/i386/i386.c (ix86_valid_target_attribute_inner_p):
Handle crc32.
* gcc.target/i386/crc32-5.c: New test.

From-SVN: r240393

8 years agore PR target/71652 (ICE in in ix86_target_macros_internal, at config/i386/i386-c...
Martin Liska [Fri, 23 Sep 2016 07:55:57 +0000 (09:55 +0200)]
re PR target/71652 (ICE in in ix86_target_macros_internal, at config/i386/i386-c.c:187)

Fix PR target/71652

PR target/71652
* config/i386/i386.c (ix86_option_override_internal): Change
signature and return false when there's an error related to
arch string.
(release_options_strings): New function.
(ix86_valid_target_attribute_tree): Call the function.
* gcc.target/i386/pr71652.c: New test.
* gcc.target/i386/pr71652-2.c: New test.
* gcc.target/i386/pr71652-3.c: New test.

From-SVN: r240392

8 years agogcc-dg.exp (process-message): Support relative line number notation - .+4 or .-1...
Jakub Jelinek [Fri, 23 Sep 2016 07:46:15 +0000 (09:46 +0200)]
gcc-dg.exp (process-message): Support relative line number notation - .+4 or .-1 etc.

* lib/gcc-dg.exp (process-message): Support relative line number
notation - .+4 or .-1 etc.
* gcc.dg/dg-test-1.c: New test.

From-SVN: r240391

8 years ago* hsa-gen.c (hsa_op_immed::hsa_op_immed Use CONSTRUCTOR_NELTS (...)
Jakub Jelinek [Fri, 23 Sep 2016 07:34:43 +0000 (09:34 +0200)]
* hsa-gen.c (hsa_op_immed::hsa_op_immed Use CONSTRUCTOR_NELTS (...)
instead of vec_safe_length (CONSTRUCTOR_ELTS (...)).
(gen_hsa_ctor_assignment): Likewise.
* print-tree.c (print_node): Likewise.
* tree-dump.c (dequeue_and_dump): Likewise.
* tree-sra.c (sra_modify_constructor_assign): Likewise.
* expr.c (store_constructor): Likewise.
* fold-const.c (operand_equal_p): Likewise.
* tree-pretty-print.c (dump_generic_node): Likewise.
* hsa-brig.c (hsa_op_immed::emit_to_buffer): Likewise.
* ipa-icf-gimple.c (func_checker::compare_operand): Likewise.
cp/
* typeck2.c (process_init_constructor_record): Use
CONSTRUCTOR_NELTS (...) instead of
vec_safe_length (CONSTRUCTOR_ELTS (...)).
* decl.c (reshape_init_r): Likewise.
(check_initializer): Likewise.
ada/
* gcc-interface/decl.c (gnat_to_gnu_entity): Use
CONSTRUCTOR_NELTS (...) instead of
vec_safe_length (CONSTRUCTOR_ELTS (...)).

From-SVN: r240390

8 years agohooks.h (hook_uint_uintp_false): Declare.
Richard Biener [Fri, 23 Sep 2016 07:22:32 +0000 (07:22 +0000)]
hooks.h (hook_uint_uintp_false): Declare.

2016-09-23  Richard Biener  <rguenther@suse.de>

* hooks.h (hook_uint_uintp_false): Declare.

From-SVN: r240389

8 years agoProvide right LDD offset bound in avr_address_cost
Senthil Kumar Selvaraj [Fri, 23 Sep 2016 07:12:35 +0000 (07:12 +0000)]
Provide right LDD offset bound in avr_address_cost

This patch fixes cost computation in avr_address_cost - instead of the
hardcoded 61, it uses the already existing MAX_LD_OFFSET(mode) macro.

This showed up when investigating a code size regression in the ivopts
pass. That pass computes address_cost with and without an offset to
decide on the right induction variable candidate(s). The legitimate
address target hook returns false for offsets more than 63, so the
pass calls the TARGET_ADDRESS_COST hook with 62 as the offset.

The avr_address_cost hook returns 18 as the cost, and the ivopts pass
concludes that the cost of address with *any* offset is 18, which is not
true - the higher cost is incurred only with offsets bigger than MAX_LD_OFFSET.
This in turn results in a suboptimal choice of induction variables in the
ivopts pass. The patch changes the hardcoded 61 to use the mode
specific MAX_LD_OFFSET instead.

Regression testing with just that fix showed one additional
compilation timeout. That turned out to be the same as
https://lists.nongnu.org/archive/html/avr-gcc-list/2014-03/msg00010.html
- the middle end takes too much time to decide on the best strategy to
multiply DImode values on a 64 bit host. This already causes timeouts
for a few builtin-arith-overflow-* tests (see
https://gcc.gnu.org/ml/gcc-testresults/2016-09/msg02018.html), so it
isn't really related to this fix. Just providing a cost estimate for
DImode mul fixes the timeout though, so the patch does that by scaling
SImode costs by 2 for DImode muls.

With both changes in, there are no regressions, and the
builtin-arith-overflow-* tests now PASS and don't timeout.

gcc/ChangeLog

2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

* config/avr/avr.c (avr_rtx_costs_1): Handle DImode MULT.
(avr_address_cost): Replace 61 with MAX_LD_OFFSET(mode).

From-SVN: r240388

8 years ago[RTEMS] Always use atomic builtins for libstdc++
Sebastian Huber [Fri, 23 Sep 2016 06:58:00 +0000 (06:58 +0000)]
[RTEMS] Always use atomic builtins for libstdc++

libstdc++-v3/
* config/cpu/m68k/atomicity.h: Adjust comment.
* acinclude.m4 (GLIBCXX_ENABLE_ATOMIC_BUILTINS): Honor
explicit atomicity_dir setup via configure.host.
* configure.host (rtems-*): Set atomicity_dir.
* configure: Regenerate.

From-SVN: r240387

8 years agoDaily bump.
GCC Administrator [Fri, 23 Sep 2016 00:16:16 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r240386

8 years agoPR target/77676 - powerpc64 and powerpc64le stage2 bootstrap fail
Martin Sebor [Thu, 22 Sep 2016 21:28:07 +0000 (21:28 +0000)]
PR target/77676 - powerpc64 and powerpc64le stage2 bootstrap fail

gcc/testsuite/ChangeLog:

PR target/77676
* gcc.dg/tree-ssa/builtin-sprintf-1.c: Define and use wint_t.
* gcc.dg/tree-ssa/builtin-sprintf-2.c: Fix typo.
* gcc.dg/tree-ssa/builtin-sprintf-3.c: New test.
* gcc.dg/tree-ssa/builtin-sprintf-warn-5.c: New test.

gcc/ChangeLog:

PR target/77676
* gimple-ssa-sprintf.c (target_int_min, target_int_max): Use
HOST_BITS_PER_WIDE_INT, make a static local variable auto.
(target_int_min): Correct computation.
(format_integer): Use long long as the argument for the ll length
modifier.
(format_floating): Use target_int_max().
(get_string_length): Same.
(format_string): Avoid setting the bounded flag for strings
of unknown length.
(try_substitute_return_value): Avoid setting range info when
the result isn't bounded.
* varasm.c (assemble_name): Increase buffer size.

From-SVN: r240383

8 years agocompiler: compile runtime.getcaller{pc,sp} into builtin functions
Ian Lance Taylor [Thu, 22 Sep 2016 20:32:16 +0000 (20:32 +0000)]
compiler: compile runtime.getcaller{pc,sp} into builtin functions

    The runtime functions runtime.getcallerpc and runtime.getcallersp are
    intended to be efficient ways to get the return and frame address of the
    caller (that is, the caller of runtime.getcallerpc).  In the C code that
    is implemented by simply using C macros:

    This patch essentially implements those macros in the Go code.

    It would be nice if we could just use //extern for this, but it doesn't
    work because the runtime code passes the right argument.  Of course we
    could change the runtime code, but these are common enough that I'd
    prefer to avoid the difference from the gc version of the runtime code.

    This patch corrects the existing declaration of __builtin_return_address
    to use uint32, rather than uint, for the parameter type.  The builtin
    functions take the C type "unsigned int", which for the targets we use
    corresponds to the Go type uint32.  Not that it should matter, really.

    Reviewed-on: https://go-review.googlesource.com/29653

From-SVN: r240382

8 years agoifcvt-1.c: Compile also for 64-bit i?86-*-* target.
Uros Bizjak [Thu, 22 Sep 2016 18:11:19 +0000 (20:11 +0200)]
ifcvt-1.c: Compile also for 64-bit i?86-*-* target.

* gcc.dg/ifcvt-1.c: Compile also for 64-bit i?86-*-* target.
* gcc.dg/ifcvt-2.c: Ditto.
* gcc.dg/zero_bits_compound-1.c: Ditto.
* gcc.dg/zero_bits_compound-1.c: Ditto.
* gcc.dg/pr40550.c: Simplify target selectors.
Use dg-additional-options.
* gcc.dg/pr47893.c: Ditto.
* gcc.dg/pr68435.c: Compile also for i?86-*-* target.  Add -march=i686
additional options for 32-bit x86 targets.
* gcc.dg/pr70955.c: Move to ...
* gcc.target/i386/pr70955.c: ... here.  Simplify target selector.

From-SVN: r240381

8 years agore PR c++/61019 (ICE: incomplete type of class template as pseudo-destructor-name)
Paolo Carlini [Thu, 22 Sep 2016 17:11:33 +0000 (17:11 +0000)]
re PR c++/61019 (ICE: incomplete type of class template as pseudo-destructor-name)

2016-09-22  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/61019
* g++.dg/cpp0x/pr61019.C: New.

From-SVN: r240380

8 years ago[ARM] Add support for -mpure-code option
Andre Vieira [Thu, 22 Sep 2016 17:02:47 +0000 (17:02 +0000)]
[ARM] Add support for -mpure-code option

gcc/ChangeLog:
2016-09-22  Andre Vieira  <andre.simoesdiasvieira@arm.com>
            Terry Guo  <terry.guo@arm.com>

    * target.def (elf_flags_numeric): New target hook.
    * targhooks.h (default_asm_elf_flags_numeric): New.
    * varasm.c (default_asm_elf_flags_numeric): New.
    (default_elf_asm_named_section): Use new target hook.
    * config/arm/arm.opt (mpure-code): New.
    * config/arm/arm.h (SECTION_ARM_PURECODE): New.
    * config/arm/arm.c (arm_asm_init_sections): Add section
    attribute to default text section if -mpure-code.
    (arm_option_check_internal): Diagnose use of option with
    non supported targets and/or options.
    (arm_asm_elf_flags_numeric): New.
    (arm_function_section): New.
    (arm_elf_section_type_flags): New.
    * config/arm/elf.h (JUMP_TABLES_IN_TEXT_SECTION): Disable
    for -mpure-code.
    * gcc/doc/texi (TARGET_ASM_ELF_FLAGS_NUMERIC): New.
    * gcc/doc/texi.in (TARGET_ASM_ELF_FLAGS_NUMERIC): Likewise.

gcc/testsuite/ChangeLog:
2016-09-22  Andre Vieira  <andre.simoesdiasvieira@arm.com>
            Terry Guo  <terry.guo@arm.com>

    * gcc.target/arm/pure-code/ffunction-sections.c: New.
    * gcc.target/arm/pure-code/no-literal-pool.c: New.
    * gcc.target/arm/pure-code/pure-code.exp: New.

Co-Authored-By: Terry Guo <terry.guo@arm.com>
From-SVN: r240379

8 years agogofrontend: add missing break in Builtin_call_expression::do_flatten
Ian Lance Taylor [Thu, 22 Sep 2016 17:02:04 +0000 (17:02 +0000)]
gofrontend: add missing break in Builtin_call_expression::do_flatten

    Reviewed-on: https://go-review.googlesource.com/29593

From-SVN: r240378

8 years agoconst-2b.c: Also compile for x86_64-*-*.
Uros Bizjak [Thu, 22 Sep 2016 16:23:20 +0000 (18:23 +0200)]
const-2b.c: Also compile for x86_64-*-*.

* gcc.dg/debug/dwarf2/const-2b.c: Also compile for x86_64-*-*.
Remove SSE effective target requirement.

From-SVN: r240377

8 years ago* MAINTAINERS (Write After Approval): Add myself.
Tamar Christina [Thu, 22 Sep 2016 15:41:03 +0000 (15:41 +0000)]
* MAINTAINERS (Write After Approval): Add myself.

From-SVN: r240375

8 years agore PR c++/71979 (ICE with on C++ code with incorrect type in overloaded base class...
Paolo Carlini [Thu, 22 Sep 2016 15:26:23 +0000 (15:26 +0000)]
re PR c++/71979 (ICE with on C++ code with incorrect type in overloaded base class '=' operator: in build_base_path, at cp/class.c:304)

/cp
2016-09-22  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/71979
* class.c (build_base_path): Allow for lookup_base returning
NULL_TREE.

/testsuite
2016-09-22  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/71979
* g++.dg/cpp0x/pr71979.C: New.

From-SVN: r240373

8 years agoRevert accidental commit.
Jan Hubicka [Thu, 22 Sep 2016 15:20:43 +0000 (15:20 +0000)]
Revert accidental commit.

From-SVN: r240369

8 years ago* regcprop.c (copyprop_hardreg_forward_1): Remove noop moves.
Jan Hubicka [Thu, 22 Sep 2016 14:34:09 +0000 (16:34 +0200)]
* regcprop.c (copyprop_hardreg_forward_1): Remove noop moves.

From-SVN: r240365

8 years agoImplement C++17 node extraction and insertion (P0083R5)
Jonathan Wakely [Thu, 22 Sep 2016 13:58:49 +0000 (14:58 +0100)]
Implement C++17 node extraction and insertion (P0083R5)

* doc/xml/manual/status_cxx2017.xml: Document status.
* doc/html/*: Regenerate.
* include/Makefile.am: Add bits/node_handle.h and reorder.
* include/Makefile.in: Regenerate.
* include/bits/hashtable.h (_Hashtable::node_type)
(_Hashtable::insert_return_type, _Hashtable::_M_reinsert_node)
(_Hashtable::_M_reinsert_node_multi, _Hashtable::extract)
(_Hashtable::_M_merge_unique, _Hashtable::_M_merge_multi): Define.
(_Hash_merge_helper): Define primary template.
* include/bits/node_handle.h: New header.
* include/bits/stl_map.h (map): Declare _Rb_tree_merge_helper as
friend.
(map::node_type, map::insert_return_type, map::extract, map::merge)
(map::insert(node_type&&), map::insert(const_iterator, node_type&&)):
Define new members.
(_Rb_tree_merge_helper): Specialize for map.
* include/bits/stl_multimap.h (multimap): Declare _Rb_tree_merge_helper
as friend.
(multimap::node_type, multimap::extract, multimap::merge)
(multimap::insert(node_type&&))
(multimap::insert(const_iterator, node_type&&)): Define.
(_Rb_tree_merge_helper): Specialize for multimap.
* include/bits/stl_multiset.h (multiset): Declare _Rb_tree_merge_helper
as friend.
(multiset::node_type, multiset::extract, multiset::merge)
(multiset::insert(node_type&&))
(multiset::insert(const_iterator, node_type&&)): Define.
* include/bits/stl_set.h (set): Declare _Rb_tree_merge_helper as
friend.
(set::node_type, set::insert_return_type, set::extract, set::merge)
(set::insert(node_type&&), set::insert(const_iterator, node_type&&)):
Define.
(_Rb_tree_merge_helper): Specialize for set.
* include/bits/stl_tree.h (_Rb_tree): Declare _Rb_tree<> as friend.
(_Rb_tree::node_type, _Rb_tree::insert_return_type)
(_Rb_tree::_M_reinsert_node_unique, _Rb_tree::_M_reinsert_node_equal)
(_Rb_tree::_M_reinsert_node_hint_unique)
(_Rb_tree::_M_reinsert_node_hint_equal, _Rb_tree::extract)
(_Rb_tree::_M_merge_unique, _Rb_tree::_M_merge_equal): Define.
(_Rb_tree_merge_helper): Specialize for multiset.
* include/bits/unordered_map.h (unordered_map): Declare
unordered_map<> and unordered_multimap<> as friends.
(unordered_map::node_type, unordered_map::insert_return_type)
(unordered_map::extract, unordered_map::merge)
(unordered_map::insert(node_type&&))
(unordered_map::insert(const_iterator, node_type&&))
(unordered_multimap): Declare _Hash_merge_helper as friend.
(unordered_multimap::node_type, unordered_multimap::extract)
(unordered_multimap::merge, unordered_multimap::insert(node_type&&))
(unordered_multimap::insert(const_iterator, node_type&&)): Define.
(_Hash_merge_helper): Specialize for unordered maps and multimaps.
* include/bits/unordered_set.h (unordered_set, unordered_multiset):
Declare _Hash_merge_helper as friend.
(unordered_set::node_type, unordered_set::insert_return_type)
(unordered_set::extract, unordered_set::merge)
(unordered_set::insert(node_type&&))
(unordered_set::insert(const_iterator, node_type&&)): Define.
(unordered_multiset::node_type, unordered_multiset::extract)
(unordered_multiset::merge, unordered_multiset::insert(node_type&&))
(unordered_multiset::insert(const_iterator, node_type&&)): Define.
(_Hash_merge_helper): Specialize for unordered sets and multisets.
* include/debug/map.h (map): Add using declarations or forwarding
functions for new members.
* include/debug/map.h (multimap): Likewise.
* include/debug/map.h (multiset): Likewise.
* include/debug/map.h (set): Likewise.
* include/debug/unordered_map (unordered_map, unordered_multimap):
Likewise.
* include/debug/unordered_set( unordered_set, unordered_multiset):
Likewise.
* python/libstdcxx/v6/printers.py (get_value_from_aligned_membuf): New
helper function.
(get_value_from_list_node, get_value_from_Rb_tree_node): Use helper.
(StdNodeHandlePrinter): Define printer for node handles.
(build_libstdcxx_dictionary): Register StdNodeHandlePrinter.
* testsuite/23_containers/map/modifiers/extract.cc: New.
* testsuite/23_containers/map/modifiers/merge.cc: New.
* testsuite/23_containers/multimap/modifiers/extract.cc: New.
* testsuite/23_containers/multimap/modifiers/merge.cc: New.
* testsuite/23_containers/multiset/modifiers/extract.cc: New.
* testsuite/23_containers/multiset/modifiers/merge.cc: New.
* testsuite/23_containers/set/modifiers/extract.cc: New.
* testsuite/23_containers/set/modifiers/merge.cc: New.
* testsuite/23_containers/unordered_map/modifiers/extract.cc: New.
* testsuite/23_containers/unordered_map/modifiers/merge.cc: New.
* testsuite/23_containers/unordered_multimap/modifiers/extract.cc:
New.
* testsuite/23_containers/unordered_multimap/modifiers/merge.cc: New.
* testsuite/23_containers/unordered_multiset/modifiers/extract.cc:
New.
* testsuite/23_containers/unordered_multiset/modifiers/merge.cc: New.
* testsuite/23_containers/unordered_set/modifiers/extract.cc: New.
* testsuite/23_containers/unordered_set/modifiers/merge.cc: New.
* testsuite/23_containers/unordered_set/instantiation_neg.cc: Adjust
dg-error lineno.
* testsuite/libstdc++-prettyprinters/cxx17.cc: Test node handles.

From-SVN: r240363

8 years agomake next_cc0_user take rtx_insn *
Trevor Saunders [Thu, 22 Sep 2016 13:17:34 +0000 (13:17 +0000)]
make next_cc0_user take rtx_insn *

gcc/ChangeLog:

2016-09-22  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>

* emit-rtl.c (next_cc0_user): Make argument type rtx_insn *.
* rtl.h: Adjust prototype.

From-SVN: r240362

8 years agomake next/prev active_insn and active_insn_p take rtx_insn *
Trevor Saunders [Thu, 22 Sep 2016 13:16:41 +0000 (13:16 +0000)]
make next/prev active_insn and active_insn_p take rtx_insn *

gcc/ChangeLog:

2016-09-22  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>

* emit-rtl.c (next_active_insn): Change argument type to
rtx_insn *.
(prev_active_insn): Likewise.
(active_insn_p): Likewise.
* rtl.h: Adjust prototypes.
* cfgcleanup.c (merge_blocks_move_successor_nojumps): Adjust.
* config/arc/arc.md: Likewise.
* config/pa/pa.c (branch_to_delay_slot_p): Likewise.
(branch_needs_nop_p): Likewise.
(use_skip_p): Likewise.
* config/sh/sh.c (gen_block_redirect): Likewise.
(split_branches): Likewise.
* reorg.c (optimize_skip): Likewise.
(fill_simple_delay_slots): Likewise.
(fill_slots_from_thread): Likewise.
(relax_delay_slots): Likewise.
* resource.c (mark_target_live_regs): Likewise.

From-SVN: r240361

8 years agomake next/prev nonnote_nondebug_insn take rtx_insn *
Trevor Saunders [Thu, 22 Sep 2016 13:16:35 +0000 (13:16 +0000)]
make next/prev nonnote_nondebug_insn take rtx_insn *

gcc/ChangeLog:

2016-09-22  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>

* config/cris/cris.c (cris_asm_output_case_end): Change argument
type to rtx_insn *.
* emit-rtl.c (next_nonnote_nondebug_insn): Likewise.
(prev_nonnote_nondebug_insn): Likewise.
* config/cris/cris-protos.h: Adjust prototype.
* rtl.h: Likewise.
* jump.c (rtx_renumbered_equal_p): Adjust.

From-SVN: r240360