]> git.ipfire.org Git - thirdparty/gcc.git/log
thirdparty/gcc.git
9 years ago2016-05-20 Richard Biener <rguenther@suse.de>
rguenth [Fri, 20 May 2016 09:01:23 +0000 (09:01 +0000)] 
2016-05-20  Richard Biener  <rguenther@suse.de>

* tree-if-conv.c (add_bb_predicate_gimplified_stmts): Use
gimple_seq_add_seq_without_update.
(release_bb_predicate): Assert we have no operands to free.
(if_convertible_loop_p_1): Calculate post dominators later.
Do not free BB predicates here.
(combine_blocks): Do not recompute BB predicates.
(version_loop_for_if_conversion): Save BB predicates around
loop versioning.

* gcc.dg/tree-ssa/ifc-cd.c: Adjust.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236498 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoChange ENABLE_VALGRIND_CHECKING to
marxin [Fri, 20 May 2016 08:03:25 +0000 (08:03 +0000)] 
Change ENABLE_VALGRIND_CHECKING to

* config.in: Regenerated.
* configure: Likewise.
* configure.ac: Handle --enable-valgrind-annotations.
* lex.c (new_buff): Use ENABLE_VALGRIND_ANNOTATIONS instead
of ENABLE_VALGRIND_CHECKING.
(_cpp_free_buff): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236496 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoDaily bump.
gccadmin [Fri, 20 May 2016 00:16:24 +0000 (00:16 +0000)] 
Daily bump.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236495 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agofunction: Restructure *logue insertion
segher [Thu, 19 May 2016 22:17:53 +0000 (22:17 +0000)] 
function: Restructure *logue insertion

This patch restructures how the prologues/epilogues are inserted.  Sibcalls
that run without prologue are now handled in shrink-wrap.c; it communicates
what is already handled by setting the EDGE_IGNORE flag.  The
try_shrink_wrapping function then doesn't need to be passed the bb_flags
anymore.

* function.c (make_epilogue_seq): Remove epilogue_end parameter.
(thread_prologue_and_epilogue_insns): Remove bb_flags.  Restructure
code.  Ignore sibcalls on EDGE_IGNORE edges.
* shrink-wrap.c (handle_simple_exit): New function.  Set EDGE_IGNORE
on edges for sibcalls that run without prologue.  The rest of the
function is combined from...
(fix_fake_fallthrough_edge): ... this, and ...
(try_shrink_wrapping): ... a part of this.  Remove the bb_with
function argument, make it a local variable.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236491 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-19 Sandra Loosemore <sandra@codesourcery.com>
sandra [Thu, 19 May 2016 21:59:45 +0000 (21:59 +0000)] 
2016-05-19  Sandra Loosemore  <sandra@codesourcery.com>

gcc/
* config/i386/cygming.h (DWARF2_UNWIND_INFO): Allow
--disable-sjlj-exceptions for TARGET_BI_ARCH to select DWARF-2 EH
for 32-bit mode and SEH for 64-bit.
* config/i386/mingw32.h (SHARED_LIBGCC_UNDEFS_SPEC): Handle
TARGET_64BIT_DEFAULT.

libgcc/
* config.host [x86_64-*-cygwin*]: Handle tmake_eh_file for mixed
dw2/seh configuration.
[x86_64-*-mingw*]: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236490 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoPR c/71171: Fix uninitialized source_range in c_parser_postfix_expression
dmalcolm [Thu, 19 May 2016 20:29:07 +0000 (20:29 +0000)] 
PR c/71171: Fix uninitialized source_range in c_parser_postfix_expression

A common way for a c_expr to have an uninitialized src_range is in
error-handling, where the "value" field is set to error_mark_node
without touching the src_range, leading to complaints from valgrind.

This patch introduces a new method c_expr::set_error which sets
the value to error_mark_node whilst initializing the src_range to
UNKNOWN_LOCATION.

This fixes the valgrind issue seen in PR c/71171, along with various
other related issues seen when running the testsuite using the
checker patch I posted here:
  https://gcc.gnu.org/ml/gcc-patches/2015-12/msg00887.html
(this checker still doesn't fully work yet, but it seems to be good
for easily detecting these issues without needing Valgrind).

gcc/c/ChangeLog:
PR c/71171
* c-parser.c (c_parser_generic_selection): Use c_expr::set_error
in error-handling.
(c_parser_postfix_expression): Likewise.
* c-tree.h (c_expr::set_error): New method.
* c-typeck.c (parser_build_binary_op): In error-handling, ensure
that result's range is initialized.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236488 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR c++/71075
mpolacek [Thu, 19 May 2016 20:23:52 +0000 (20:23 +0000)] 
PR c++/71075
* pt.c (unify_template_argument_mismatch): Use %qE instead of %qD.

* g++.dg/diagnostic/pr71075.C: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236487 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago Fix handling of non-dependent calls with default template args.
jason [Thu, 19 May 2016 19:20:40 +0000 (19:20 +0000)] 
Fix handling of non-dependent calls with default template args.

PR c++/10200
* pt.c (fn_type_unification): Add outer template args if needed.
(type_unification_real): Handle getting full args.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236486 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoPR c++/71184: Fix NULL dereference in cp_parser_operator
dmalcolm [Thu, 19 May 2016 18:10:30 +0000 (18:10 +0000)] 
PR c++/71184: Fix NULL dereference in cp_parser_operator

The source-range handling for the array form of operator
new/delete erroneously assumed that the "]" was present,
leading to a dereference of NULL when it's absent.

Fix it thusly.

gcc/cp/ChangeLog:
PR c++/71184
* parser.c (cp_parser_operator): For array new/delete, check that
cp_parser_require returned a non-NULL token before dereferencing
it.

gcc/testsuite/ChangeLog:
PR c++/71184
* g++.dg/pr71184.C: New test case.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236483 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-16 Ryan Burn <contact@rnburn.com>
law [Thu, 19 May 2016 18:03:30 +0000 (18:03 +0000)] 
2016-05-16  Ryan Burn  <contact@rnburn.com>

  * Makefile.in (GTFILES): Add cilk.h and cilk-common.c.
  * gengtype.c (open_base_files): Add cilk.h to ifiles.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236482 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * sched-deps.c (sched_analyze_2) <case TRAP_IF>: Also
uros [Thu, 19 May 2016 17:52:56 +0000 (17:52 +0000)] 
* sched-deps.c (sched_analyze_2) <case TRAP_IF>: Also
force pending loads from memory.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236481 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agogcc/testsuite/ChangeLog:
kelvin [Thu, 19 May 2016 17:47:40 +0000 (17:47 +0000)] 
gcc/testsuite/ChangeLog:

2016-05-19  Kelvin Nilsen  <kelvin@gcc.gnu.org>

* gcc.target/powerpc/darn-0.c: New test.
* gcc.target/powerpc/darn-1.c: New test.
* gcc.target/powerpc/darn-2.c: New test.

gcc/ChangeLog:

2016-05-19  Kelvin Nilsen  <kelvin@gcc.gnu.org>

* config/rs6000/altivec.md (UNSPEC_DARN): New unspec constant.
(UNSPEC_DARN_32): New unspec constant.
(UNSPEC_DARN_RAW): New unspec constant.
(darn_32): New instruction.
(darn_raw): New instruction.
(darn): New instruction.
* config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_0): Add
support and documentation for this macro.
(BU_P9_MISC_1): New macro definition.
(BU_P9_64BIT_MISC_0): New macro definition.
(BU_P9_MISC_0): New macro definition.
(darn_32): New builtin definition.
(darn_raw): New builtin definition.
(darn): New builtin definition.
* config/rs6000/rs6000.c: Add #define RS6000_BUILTIN_0 and #undef
RS6000_BUILTIN_0 directives to surround each occurrence of
#include "rs6000-builtin.def".
(rs6000_builtin_mask_calculate): Add in the RS6000_BTM_MODULO and
RS6000_BTM_64BIT flags to the returned mask, depending on
configuration.
(def_builtin): Correct an error in the assignments made to the
debugging variable attr_string.
(rs6000_expand_builtin): Add support for no-operand built-in
functions.
(builtin_function_type): Remove fatal_error assertion that is no
longer valid.
(rs6000_common_init_builtins): Add support for no-operand built-in
functions.
* config/rs6000/rs6000.h (RS6000_BTM_MODULO): New macro
definition.
(RS6000_BTM_PURE): Enhance comment to clarify intent of this flag
definition.
(RS6000_BTM_64BIT): New macro definition.
* doc/extend.texi: Document __builtin_darn (void),
__builtin_darn_raw (void), and __builtin_darn_32 (void) built-in
functions.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236480 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * tree-vect-loop.c (vect_analyze_loop_2): Use also
hubicka [Thu, 19 May 2016 15:50:56 +0000 (15:50 +0000)] 
* tree-vect-loop.c (vect_analyze_loop_2): Use also
max_loop_iterations_int.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236478 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR tree-optimization/71031
mpolacek [Thu, 19 May 2016 15:45:35 +0000 (15:45 +0000)] 
PR tree-optimization/71031
* tree-vrp.c (extract_range_from_binary_expr_1): Turn assert into a
condition and adjust the code a bit.

* gcc.dg/tree-ssa/vrp100.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236477 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix memory leak in tree-vect-stmts.c
marxin [Thu, 19 May 2016 15:08:02 +0000 (15:08 +0000)] 
Fix memory leak in tree-vect-stmts.c

* tree-vect-stmts.c (vectorizable_simd_clone_call): Utilize
auto_vec instead of vec.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236472 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix memory leak in tree-parloops.c
marxin [Thu, 19 May 2016 15:07:28 +0000 (15:07 +0000)] 
Fix memory leak in tree-parloops.c

* tree-parloops.c (oacc_entry_exit_ok): Release a vector.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236471 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix memory leak in tree-if-conv.c
marxin [Thu, 19 May 2016 15:06:47 +0000 (15:06 +0000)] 
Fix memory leak in tree-if-conv.c

* tree-if-conv.c (ifcvt_repair_bool_pattern): Utilize auto_vecs.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236470 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix memory leak in ipa-pure-const
marxin [Thu, 19 May 2016 15:06:17 +0000 (15:06 +0000)] 
Fix memory leak in ipa-pure-const

* ipa-pure-const.c (set_function_state): Remove an existing
funct_state.
(remove_node_data): Do not free it as it's released
in set_function_state.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236469 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix memory leak in tree-vect-slp.c
marxin [Thu, 19 May 2016 15:05:53 +0000 (15:05 +0000)] 
Fix memory leak in tree-vect-slp.c

* tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Release
bitmap.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236468 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix memory leak in omp-simd-clone.c
marxin [Thu, 19 May 2016 15:05:26 +0000 (15:05 +0000)] 
Fix memory leak in omp-simd-clone.c

* omp-simd-clone.c (simd_clone_adjust): Release vector.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236467 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix leak in gcc/tree-ssa-reassoc.c.
marxin [Thu, 19 May 2016 15:05:07 +0000 (15:05 +0000)] 
Fix leak in gcc/tree-ssa-reassoc.c.

* tree-ssa-reassoc.c (eliminate_duplicate_pair): Truncate
an auto_vec instead of re-creating it.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236466 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix leak in tree-ssa-loop-prefetch.c
marxin [Thu, 19 May 2016 15:04:42 +0000 (15:04 +0000)] 
Fix leak in tree-ssa-loop-prefetch.c

* tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Use
auto_vec instead of vec.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236465 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoLTO: display file name if LTO version check fails
marxin [Thu, 19 May 2016 15:02:30 +0000 (15:02 +0000)] 
LTO: display file name if LTO version check fails

* lto-section-in.c (lto_get_section_data): Call
lto_check_version with additional argument.
* lto-streamer.c (lto_check_version): Add new argument.
* lto-streamer.h (lto_check_version): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236464 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[ARM] Fix costing of sign-extending load in rtx costs
ktkachov [Thu, 19 May 2016 13:54:31 +0000 (13:54 +0000)] 
[ARM] Fix costing of sign-extending load in rtx costs

* config/arm/arm.c (arm_new_rtx_costs, SIGN_EXTEND case):
Don't add cost of inner memory when handling sign-extended
loads.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236461 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agogcc/
ienkovich [Thu, 19 May 2016 13:50:22 +0000 (13:50 +0000)] 
gcc/

* cse.c (cse_main): Free dominance info.
(rest_of_handle_cse): Don't free dominance info.
(rest_of_handle_cse2): Likewise.
(rest_of_handle_cse_after_global_opts): Likewise.

gcc/testsuite/

* gcc.dg/pr71148.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236460 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[ARM] PR target/71056: Don't use vectorized builtins when NEON is not available
ktkachov [Thu, 19 May 2016 13:43:58 +0000 (13:43 +0000)] 
[ARM] PR target/71056: Don't use vectorized builtins when NEON is not available

PR target/71056
* config/arm/arm-builtins.c (arm_builtin_vectorized_function): Return
NULL_TREE early if NEON is not available.  Remove now redundant check
in ARM_CHECK_BUILTIN_MODE.

* gcc.target/arm/pr71056.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236459 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-19 Bernd Edlinger <bernd.edlinger@hotmail.de>
edlinger [Thu, 19 May 2016 12:27:31 +0000 (12:27 +0000)] 
2016-05-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        * decl.c (finish_enum_value_list): Use the specified mode.

testsuite:
2016-05-19  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        * c-c++-common/pr69669.c: Check the used mode.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236458 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-19 Maxim Ostapenko <m.ostapenko@samsung.com>
chefmax [Thu, 19 May 2016 12:05:59 +0000 (12:05 +0000)] 
2016-05-19  Maxim Ostapenko  <m.ostapenko@samsung.com>

PR sanitizer/64354
* cppbuiltin.c (define_builtin_macros_for_compilation_flags): Add new
builtin __SANITIZE_THREAD__ macros for fsanitize=thread switch.
* doc/cpp.texi: Document new macros.

* c-c++-common/tsan/sanitize-thread-macro.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236457 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoMove ChangeLog entry to the right file.
jakub [Thu, 19 May 2016 09:55:01 +0000 (09:55 +0000)] 
Move ChangeLog entry to the right file.
PR other/61321
PR other/61233
* demangle.h (enum demangle_component_type)
<DEMANGLE_COMPONENT_CONVERSION>: New value.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236449 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoRemove libiberty/ path prefixes.
jakub [Thu, 19 May 2016 09:27:57 +0000 (09:27 +0000)] 
Remove libiberty/ path prefixes.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236448 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR tree-optimization/69848
amker [Thu, 19 May 2016 09:03:36 +0000 (09:03 +0000)] 
PR tree-optimization/69848
* tree-vect-loop.c (vectorizable_reduction): Don't factor
comparison expr out of VEC_COND_EXPR for COND_REDUCTION.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236447 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR c++/70498
jakub [Thu, 19 May 2016 08:49:30 +0000 (08:49 +0000)] 
PR c++/70498
* cp-demangle.c (d_expression_1): Formatting fix.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236445 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix up 2 ChangeLog entries.
jakub [Thu, 19 May 2016 08:34:39 +0000 (08:34 +0000)] 
Fix up 2 ChangeLog entries.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236443 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agofunction: A fix for my previous commit
segher [Thu, 19 May 2016 07:51:48 +0000 (07:51 +0000)] 
function: A fix for my previous commit

It failed for targets that have an eh_return pattern with a splitter
gated by epilogue_done.

        * function.c (thread_prologue_and_epilogue_insn): Move the
        "goto epilogue_done" one block later.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236441 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-19 Richard Biener <rguenther@suse.de>
rguenth [Thu, 19 May 2016 07:39:52 +0000 (07:39 +0000)] 
2016-05-19  Richard Biener  <rguenther@suse.de>

PR tree-optimization/70729
* passes.def: Move LIM pass before PRE.  Remove no longer
required copyprop and move first DCE out of the loop pipeline.

* gcc.dg/autopar/outer-6.c: Adjust to avoid redundant store.
* gcc.dg/graphite/scop-18.c: Likewise.
* gcc.dg/pr41783.c: Disable LIM.
* gcc.dg/tree-ssa/loadpre10.c: Likewise.
* gcc.dg/tree-ssa/loadpre23.c: Likewise.
* gcc.dg/tree-ssa/loadpre24.c: Likewise.
* gcc.dg/tree-ssa/loadpre25.c: Likewise.
* gcc.dg/tree-ssa/loadpre4.c: Likewise.
* gcc.dg/tree-ssa/loadpre8.c: Likewise.
* gcc.dg/tree-ssa/ssa-pre-16.c: Likewise.
* gcc.dg/tree-ssa/ssa-pre-18.c: Likewise.
* gcc.dg/tree-ssa/ssa-pre-20.c: Likewise.
* gcc.dg/tree-ssa/ssa-pre-3.c: Likewise.
* gfortran.dg/pr42108.f90: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236440 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoPR driver/69265: add hint for options with misspelled arguments
dmalcolm [Thu, 19 May 2016 00:52:08 +0000 (00:52 +0000)] 
PR driver/69265: add hint for options with misspelled arguments

opts-common.c's cmdline_handle_error handles invalid arguments
for options with CL_ERR_ENUM_ARG by building a string listing the
valid arguments.  By also building a vec of valid arguments, we
can use find_closest_string and provide a hint if we see a close
misspelling.

gcc/ChangeLog:
PR driver/69265
* Makefile.in (GCC_OBJS): Move spellcheck.o to...
(OBJS-libcommon-target): ...here.
* opts-common.c: Include spellcheck.h.
(cmdline_handle_error): Build a vec of valid options and use it
to suggest provide hints for misspelled arguments.

gcc/testsuite/ChangeLog:
PR driver/69265
* gcc.dg/spellcheck-options-11.c: New test case.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236439 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoDaily bump.
gccadmin [Thu, 19 May 2016 00:16:21 +0000 (00:16 +0000)] 
Daily bump.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236438 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * cplus-dem.c (enum type_kind_t): Add tk_rvalue_reference
law [Wed, 18 May 2016 21:52:26 +0000 (21:52 +0000)] 
    * cplus-dem.c (enum type_kind_t): Add tk_rvalue_reference
        constant.
        (demangle_template_value_parm): Handle tk_rvalue_reference
        type kind.
        (do_type): Support 'O' type id (rvalue references).

        * testsuite/demangle-expected: Add tests.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236434 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR c++/71100
jakub [Wed, 18 May 2016 21:23:07 +0000 (21:23 +0000)] 
PR c++/71100
* cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Don't drop
lhs if it has TREE_ADDRESSABLE type.

* g++.dg/opt/pr71100.C: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236430 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR target/71145
uros [Wed, 18 May 2016 19:15:22 +0000 (19:15 +0000)] 
PR target/71145
* config/alpha/alpha.md (trap): Add (use (reg:DI 29)).
(*exception_receiver_1): Return "#" for TARGET_EXPLICIT_RELOCS.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236423 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * pt.c (value_dependent_expression_p): Tweak new cases to better
jason [Wed, 18 May 2016 17:43:18 +0000 (17:43 +0000)] 
* pt.c (value_dependent_expression_p): Tweak new cases to better
match the wording in the standard.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236421 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoAllow constant global VAR_DECLs in constant jump functions
jamborm [Wed, 18 May 2016 16:44:08 +0000 (16:44 +0000)] 
Allow constant global VAR_DECLs in constant jump functions

2016-05-18  Martin Jambor  <mjambor@suse.cz>

PR ipa/69708
* ipa-cp.c (ipa_get_jf_pass_through_result): Allow non-ip constant
input for NOP_EXPR pass-through functions.
* ipa-prop.c (ipa_compute_jump_functions_for_edge): Allow
aggregate global constant VAR_DECLs in constant jump functions.

testsuite/
* gcc.dg/ipa/iinline-cstagg-2.c: New test.
* gcc.dg/ipa/ipcp-cstagg-5.c: Likewise.
* gcc.dg/ipa/ipcp-cstagg-6.c: Likewise.
* gcc.dg/ipa/ipcp-cstagg-7.c: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236418 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoConst parameters are always unmodified
jamborm [Wed, 18 May 2016 16:41:19 +0000 (16:41 +0000)] 
Const parameters are always unmodified

2016-05-18  Martin Jambor  <mjambor@suse.cz>

PR ipa/69708
* ipa-prop.c (parm_preserved_before_stmt_p): Return true for loads
from TREE_READONLY parameters.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236417 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoIndirect inlining of targets from references of global constants
jamborm [Wed, 18 May 2016 16:38:56 +0000 (16:38 +0000)] 
Indirect inlining of targets from references of global constants

2016-05-18  Martin Jambor  <mjambor@suse.cz>

PR ipa/69708
* cgraph.h (cgraph_indirect_call_info): New field
guaranteed_unmodified.
* ipa-cp.c (ipa_get_indirect_edge_target_1): Also pass parameter value
to ipa_find_agg_cst_for_param, check guaranteed_unmodified when
appropriate.
* ipa-inline-analysis.c (evaluate_conditions_for_known_args): Also
pass the parameter value to ipa_find_agg_cst_for_param.
* ipa-prop.c (ipa_load_from_parm_agg): New parameter
guaranteed_unmodified, store AA results there instead of bailing out
if present.
(ipa_note_param_call): Also initialize guaranteed_unmodified flag.
(ipa_analyze_indirect_call_uses): Also set guaranteed_unmodified flag.
(find_constructor_constant_at_offset): New function.
(ipa_find_agg_cst_from_init): Likewise.
(ipa_find_agg_cst_for_param): Also seearch for aggregate values in
static initializers of contants, report back through a new paameter
from_global_constant if that was the case.
(try_make_edge_direct_simple_call): Also pass parameter value to
ipa_find_agg_cst_for_param, check guaranteed_unmodified when
appropriate.
(ipa_write_indirect_edge_info): Stream new flag guaranteed_unmodified.
(ipa_read_indirect_edge_info): Likewise.
* ipa-prop.h (ipa_find_agg_cst_for_param): Update declaration.
(ipa_load_from_parm_agg): Likewise.

testsuite/
* gcc.dg/ipa/iinline-cstagg-1.c: New test.
* gcc.dg/ipa/ipcp-cstagg-1.c: Likewise.
* gcc.dg/ipa/ipcp-cstagg-2.c: Likewise.
* gcc.dg/ipa/ipcp-cstagg-3.c: Likewise.
* gcc.dg/ipa/ipcp-cstagg-4.c: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236416 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago/cp
paolo [Wed, 18 May 2016 16:26:35 +0000 (16:26 +0000)] 
/cp
2016-05-18  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/69793
* parser.c (cp_parser_template_id): Don't call cp_lexer_peek_nth_token
when the previous cp_lexer_peek_token returns CPP_EOF.

/testsuite
2016-05-18  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/69793
* g++.dg/template/crash122.C: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236414 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR target/71161
uros [Wed, 18 May 2016 14:40:54 +0000 (14:40 +0000)] 
PR target/71161
* elf.c (phdr_callback) [__i386__]: Add
__attribute__((__force_align_arg_pointer__)).

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236397 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[Patch, lra] Guard in_class_p with REG_P check
jiwang [Wed, 18 May 2016 14:37:28 +0000 (14:37 +0000)] 
[Patch, lra] Guard in_class_p with REG_P check

gcc/

PR rtl-optimization/71150
* lra-constraint (process_addr_reg): Guard "in_class_p" with REG_P
check.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236396 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago/cp
paolo [Wed, 18 May 2016 14:18:06 +0000 (14:18 +0000)] 
/cp
2016-05-18  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/70466
* call.c (convert_like_real): Check that we are actually converting
from an init list.

/testsuite
2016-05-18  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/70466
* g++.dg/template/pr70466-1.C: New.
* g++.dg/template/pr70466-2.C: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236395 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[gcc]
meissner [Wed, 18 May 2016 14:04:32 +0000 (14:04 +0000)] 
[gcc]
2016-05-18  Michael Meissner  <meissner@linux.vnet.ibm.com>

PR target/70915
* config/rs6000/constraints.md (wE constraint): New constraint
for a vector constant that can be loaded with XXSPLTIB.
(wM constraint): New constraint for a vector constant of a 1's.
(wS constraint): New constraint for a vector constant that can be
loaded with XXSPLTIB and a vector sign extend instruction.
* config/rs6000/predicates.md (xxspltib_constant_split): New
predicates for wE/wS constraints.
(xxspltib_constant_nosplit): Likewise.
(easy_vector_constant): Add support for constants that can be
loaded via XXSPLTIB.
(all_ones_constant): New predicate for vector constant with all
1's set.
(splat_input_operand): Add support for ISA 3.0 word splat
operations.
* config/rs6000/rs6000.c (xxspltib_constant_p): New function to
return if a constant can be loaded with the ISA 3.0 XXSPLTIB
instruction and possibly with a sign extension.
(output_vec_const_move): Add support for XXSPLTIB. If we are
loading up 0/-1 into Altivec registers, prefer using VSPLTISW
instead of XXLXOR/XXLORC.
(rs6000_expand_vector_init): Add support for ISA 3.0 word splat
operations.
(rs6000_legitimize_reload_address): Likewise.
(rs6000_output_move_128bit): Use output_vec_const_move to emit
constants.
* config/rs6000/vsx.md (VSX_M): Add TImode (if -mvsx-timode) and
combine VSX_M and VSX_M2 into one iterator.
(VSX_M2): Likewise.
(VSINT_84): New iterators for loading constants with XXSPLTIB.
(VSINT_842): Likewise.
(UNSPEC_VSX_SIGN_EXTEND): New UNSPEC.
(xxspltib_v16qi): New insns to load up constants with the ISA 3.0
XXSPLTIB instruction.
(xxspltib_<mode>_nosplit): Likewise.
(xxspltib_<mode>_split): New insn to load up constants with
XXSPLTIB and a sign extend instruction.
(vsx_mov<mode>): Replace single move that handled all vector types
with separate 32-bit and 64-bit moves.  Combine the movti_<bit>
moves (when -mvsx-timode is in effect) into the main vector
moves.  Eliminate separate moves for <VSr> <VSa>, where the
preferred register class (<VSr>) is listed first, and the
secondary register class (<VSa>) is listed second with a '?' to
discourage use.  Prefer loading 0/-1 in any VSX register for ISA
3.0, and Altivec registers for ISA 2.06/2.07 (PR target/70915) so
that if the register was involved in a slow operation, the
clear/set operation does not wait for the slow operation to
finish.  Adjust the length attributes for 32-bit mode.  Use
rs6000_output_move_128bit and drop the use of the string
instructions for 32-bit movti when -mvsx-timode is in effect.  Use
spacing so that the alternatives and attributes don't generate
long lines, and put things in columns, so that it is easier to
match up the operands and attributes with the insn alternatives.
(vsx_mov<mode>_64bit): Likewise.
(vsx_mov<mode>_32bit): Likewise.
(vsx_movti_64bit): Fold movti into normal vector moves.
(vsx_movti_32bit): Likewise.
(vsx_splat_<mode>, V4SI/V4SF modes): Add support for ISA 3.0 word
spat instructions.
(vsx_splat_v4si_internal): Likewise.
(vsx_splat_v4sf_internal): Likewise.
(vector fusion peepholes): Use VSX_M instead of VSX_M2.
(vsx_sign_extend_qi_<mode>): New ISA 3.0 instructions to sign
extend vector elements.
(vsx_sign_extend_hi_<mode>): Likewise.
(vsx_sign_extend_si_v2di): Likewise.
* config/rs6000/rs6000-protos.h (xxspltib_constant_p): Add
declaration.
* doc/md.texi (PowerPC constraints): Document the wE, wM, and wS
constraints.  Add trailing period to wL documentation.

[gcc/testsuite]
2016-05-18  Michael Meissner  <meissner@linux.vnet.ibm.com>

* gcc.target/powerpc/p9-splat-1.c: New tests for ISA 3.0 word
splat operations and the XXSPLTIB instruction.
* gcc.target/powerpc/p9-splat-2.c: Likewise.
* gcc.target/powerpc/p9-splat-3.c: Likewise.
* gcc.target/powerpc/pr47755.c: Allow vspltisw in addition to
xxlxor to clear a register.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236394 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoTo: gcc-patches@gcc.gnu.org
rsandifo [Wed, 18 May 2016 14:01:31 +0000 (14:01 +0000)] 
To: gcc-patches@gcc.gnu.org
Subject: PR 71020: Handle abnormal PHIs in tree-call-cdce.c
From: Richard Sandiford <richard.sandiford@arm.com>
Gcc: private.sent
--text follows this line--
The PR is about a case where tree-call-cdce.c causes two abnormal
PHIs for the same variable to be live at the same time, leading to
a coalescing failure.  It seemed like getting rid of these kinds of
input would be generally useful, so I added a utility to tree-dfa.c.

Tested on x86_64-linux-gnu.

gcc/
PR middle-end/71020
* tree-dfa.h (replace_abnormal_ssa_names): Declare.
* tree-dfa.c (replace_abnormal_ssa_names): New function.
* tree-call-cdce.c: Include tree-dfa.h.
(can_guard_call_p): New function, extracted from...
(can_use_internal_fn): ...here.
(shrink_wrap_one_built_in_call_with_conds): Remove failure path
and return void.
(shrink_wrap_one_built_in_call): Likewise.
(use_internal_fn): Likewise.
(shrink_wrap_conditional_dead_built_in_calls): Update accordingly
and return void.  Call replace_abnormal_ssa_names.
(pass_call_cdce::execute): Check can_guard_call_p during the
initial walk.  Assume shrink_wrap_conditional_dead_built_in_calls
will always change something.

gcc/testsuite/
* gcc.dg/torture/pr71020.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236393 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoRespect --param ipa-max-agg-items=0
jamborm [Wed, 18 May 2016 13:06:24 +0000 (13:06 +0000)] 
Respect --param ipa-max-agg-items=0

2016-05-18  Martin Jambor  <mjambor@suse.cz>

PR ipa/70646
* ipa-prop.c (determine_locally_known_aggregate_parts): Bail out early
if parameter PARAM_IPA_MAX_AGG_ITEMS is zero.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236390 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[PR 70646] Store size to inlining predicate conditions
jamborm [Wed, 18 May 2016 13:04:23 +0000 (13:04 +0000)] 
[PR 70646] Store size to inlining predicate conditions

2016-05-18  Martin Jambor  <mjambor@suse.cz>

PR ipa/70646
* ipa-inline.h (condition): New field size.
* ipa-inline-analysis.c (add_condition): New parameter SIZE, use it
for comaprison and store it into the new condition.
(evaluate_conditions_for_known_args): Use condition size to check
access sizes for all but CHANGED conditions.
(unmodified_parm_1): New parameter size_p, store access size into it.
(unmodified_parm): Likewise.
(unmodified_parm_or_parm_agg_item): Likewise.
(eliminated_by_inlining_prob): Pass NULL to unmodified_parm as size_p.
(set_cond_stmt_execution_predicate): Extract access sizes and store
them to conditions.
(set_switch_stmt_execution_predicate): Likewise.
(will_be_nonconstant_expr_predicate): Likewise.
(will_be_nonconstant_predicate): Likewise.
(inline_read_section): Stream condition size.
(inline_write_summary): Likewise.

testsuite/
* gcc.dg/ipa/pr70646.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236389 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago* gcc.target/aarch64/advsimd-intrinsics/vget_lane.c: Add fp16 tests.
clyon [Wed, 18 May 2016 12:57:53 +0000 (12:57 +0000)] 
* gcc.target/aarch64/advsimd-intrinsics/vget_lane.c: Add fp16 tests.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236388 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago* gcc.target/aarch64/advsimd-intrinsics/vreinterpret.c: Add missing tests for vreinte...
clyon [Wed, 18 May 2016 12:54:13 +0000 (12:54 +0000)] 
* gcc.target/aarch64/advsimd-intrinsics/vreinterpret.c: Add missing tests for vreinterpretq_p{8,16}.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236387 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago* gcc.target/aarch64/advsimd-intrinsics/vsli_n.c: Add checks for vsliq_n_s64 and...
clyon [Wed, 18 May 2016 12:52:51 +0000 (12:52 +0000)] 
* gcc.target/aarch64/advsimd-intrinsics/vsli_n.c: Add checks for vsliq_n_s64 and vsliq_n_u64.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236385 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * gcc.target/aarch64/advsimd-intrinsics/arm-neon-ref.h (CHECK,
clyon [Wed, 18 May 2016 12:50:34 +0000 (12:50 +0000)] 
* gcc.target/aarch64/advsimd-intrinsics/arm-neon-ref.h (CHECK,
CHECK_FP, CHECK_CUMULATIVE_SAT): Print which type was checked.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236384 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * gcc.target/aarch64/advsimd-intrinsics/vmul.c: Remove useless #ifdef.
clyon [Wed, 18 May 2016 12:48:47 +0000 (12:48 +0000)] 
* gcc.target/aarch64/advsimd-intrinsics/vmul.c: Remove useless #ifdef.
* gcc.target/aarch64/advsimd-intrinsics/vshl.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vtst.c: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236383 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago* gcc.target/aarch64/advsimd-intrinsics/vreinterpret.c: Fix typo in comment.
clyon [Wed, 18 May 2016 12:46:23 +0000 (12:46 +0000)] 
* gcc.target/aarch64/advsimd-intrinsics/vreinterpret.c: Fix typo in comment.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236382 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix ChangeLog date.
clyon [Wed, 18 May 2016 12:41:50 +0000 (12:41 +0000)] 
Fix ChangeLog date.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236381 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * gcc.target/aarch64/noplt_3.c: Scan for "br\t".
clyon [Wed, 18 May 2016 12:33:36 +0000 (12:33 +0000)] 
* gcc.target/aarch64/noplt_3.c: Scan for "br\t".
* gcc.target/aarch64/tail_indirect_call_1.c: Scan for "br\t",
"blr\t" and switch to scan-assembler-times.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236377 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-18 Richard Biener <rguenther@suse.de>
rguenth [Wed, 18 May 2016 12:32:46 +0000 (12:32 +0000)] 
2016-05-18  Richard Biener  <rguenther@suse.de>

* tree-ssa-loop-im.c (determine_max_movement): Properly add
condition cost to PHI cost instead of total_cost.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236376 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoSet DECL_PT_UID for merged variables in IPA ICF (PR70856).
marxin [Wed, 18 May 2016 11:48:50 +0000 (11:48 +0000)] 
Set DECL_PT_UID for merged variables in IPA ICF (PR70856).

PR fortran/70856
* ipa-icf.c (sem_variable::merge): Set DECL_PT_UID for
merged variables.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236375 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-18 Richard Biener <rguenther@suse.de>
rguenth [Wed, 18 May 2016 11:21:33 +0000 (11:21 +0000)] 
2016-05-18  Richard Biener  <rguenther@suse.de>

* lto-streamer.h (LTO_major_version): Bump to 6.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236374 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agofunction: Factor out make_*logue_seq
segher [Wed, 18 May 2016 11:07:20 +0000 (11:07 +0000)] 
function: Factor out make_*logue_seq

Make new functions make_split_prologue_seq, make_prologue_seq, and
make_epilogue_seq.

* function.c (make_split_prologue_seq, make_prologue_seq,
make_epilogue_seq): New functions, factored out from...
(thread_prologue_and_epilogue_insns): Here.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236373 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agofunction: Do the CLEANUP_EXPENSIVE after shrink-wrapping, not before
segher [Wed, 18 May 2016 10:58:57 +0000 (10:58 +0000)] 
function: Do the CLEANUP_EXPENSIVE after shrink-wrapping, not before

We should do CLEANUP_EXPENSIVE after shrink-wrapping, because shrink-
wrapping creates constructs that CLEANUP_EXPENSIVE can optimise, and
nothing runs CLEANUP_EXPENSIVE later.

* function.c (rest_of_handle_thread_prologue_and_epilogue): Call
cleanup_cfg with CLEANUP_EXPENSIVE after shrink-wrapping instead
of before.  Add a comment.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236372 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * tree-ssa-loop-ivopts.c (get_computation_cost_at): Check inv
amker [Wed, 18 May 2016 10:41:28 +0000 (10:41 +0000)] 
* tree-ssa-loop-ivopts.c (get_computation_cost_at): Check inv
expression pointer, not pointer to the pointer.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236371 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[testsuite] Guard float64_t with __aarch64__
jiwang [Wed, 18 May 2016 09:43:04 +0000 (09:43 +0000)] 
[testsuite] Guard float64_t with __aarch64__

gcc/testsuite/
        * gcc.target/aarch64/advsimd-intrinsics/arm-neon-ref.h: Guard float64_t
        with __aarch64__.
        * gcc.target/aarch64/advsimd-intrinsics/vfms_vfma_n.c: Guard variable
        declarations under __aarch64__ and __ARM_FEATURE_FMA.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236370 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * config/i386/sse.md (pbroadcast_evex_isa): New mode attr.
jakub [Wed, 18 May 2016 09:24:59 +0000 (09:24 +0000)] 
* config/i386/sse.md (pbroadcast_evex_isa): New mode attr.
(avx2_pbroadcast<mode>): Add another alternative with v instead
of x constraints in it, using <pbroadcast_evex_isa> isa.
(avx2_pbroadcast<mode>_1): Similarly, add two such alternatives.

* gcc.target/i386/avx512bw-vpbroadcast-1.c: New test.
* gcc.target/i386/avx512bw-vpbroadcast-2.c: New test.
* gcc.target/i386/avx512bw-vpbroadcast-3.c: New test.
* gcc.target/i386/avx512vl-vpbroadcast-1.c: New test.
* gcc.target/i386/avx512vl-vpbroadcast-2.c: New test.
* gcc.target/i386/avx512vl-vpbroadcast-3.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236369 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * config/i386/sse.md (<ssse3_avx2>_palignr<mode>): Use
jakub [Wed, 18 May 2016 09:24:15 +0000 (09:24 +0000)] 
* config/i386/sse.md (<ssse3_avx2>_palignr<mode>): Use
constraint x instead of v in second alternative, add avx512bw
alternative.

* gcc.target/i386/avx512vl-vpalignr-3.c: New test.
* gcc.target/i386/avx512bw-vpalignr-3.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236368 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * config/i386/sse.md (<ssse3_avx2>_pshufb<mode>3<mask_name>): Use
jakub [Wed, 18 May 2016 09:23:39 +0000 (09:23 +0000)] 
* config/i386/sse.md (<ssse3_avx2>_pshufb<mode>3<mask_name>): Use
constraint x instead of v in second alternative, add avx512bw
alternative.

* gcc.target/i386/avx512vl-vpshufb-3.c: New test.
* gcc.target/i386/avx512bw-vpshufb-3.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236367 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * config/i386/sse.md (*<ssse3_avx2>_pmulhrsw<mode>3<mask_name>): Use
jakub [Wed, 18 May 2016 09:23:03 +0000 (09:23 +0000)] 
* config/i386/sse.md (*<ssse3_avx2>_pmulhrsw<mode>3<mask_name>): Use
constraint x instead of v in second alternative, add avx512bw
alternative.

* gcc.target/i386/avx512vl-vpmulhrsw-3.c: New test.
* gcc.target/i386/avx512bw-vpmulhrsw-3.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236366 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * config/i386/sse.md (avx2_pmaddubsw256, ssse3_pmaddubsw128): Add
jakub [Wed, 18 May 2016 09:22:28 +0000 (09:22 +0000)] 
* config/i386/sse.md (avx2_pmaddubsw256, ssse3_pmaddubsw128): Add
avx512bw alternative.

* gcc.target/i386/avx512bw-vpmaddubsw-3.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236365 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoi386. Extend static buffers. Fix SF mode operand constraint to `Yv' in storehpd pattern.
kyukhin [Wed, 18 May 2016 09:16:09 +0000 (09:16 +0000)] 
i386. Extend static buffers. Fix SF mode operand constraint to `Yv' in storehpd pattern.

gcc/
        * gcc/config/i386/sse.md (define_insn "*andnot<mode>3"): Extend static
array to 128 chars.
(define_insn "*andnottf3"): Ditto.
(define_insn "*<code><mode>3"/any_logic): Ditto.
(define_insn "*<code>tf3"/any_logic): Ditto.
(define_insn "sse2_storehpd"): Use Yv constraint for scalar
operand to block AVX-512VL insn variant emit when it is not enabled.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236364 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoAVX-512. Use `Yv' for SF mode operand in vec_concat pattern.
kyukhin [Wed, 18 May 2016 09:11:10 +0000 (09:11 +0000)] 
AVX-512. Use `Yv' for SF mode operand in vec_concat pattern.

gcc/
* config/i386/sse.md (define_insn "*vec_concatv2sf_sse4_1"): Use 'Yv'
constraint fot SF mode.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236363 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix patterns to enable sse-14.c to compile with -masm=intel.
kyukhin [Wed, 18 May 2016 09:06:11 +0000 (09:06 +0000)] 
Fix patterns to enable sse-14.c to compile with -masm=intel.

gcc/
        * config/i386/sse.md (define_insn "srcp14<mode>"): Use proper operand
modifiers.
(define_insn "rsqrt14<mode>"): Ditto.
(define_insn "<mask_codefor>avx512dq_cvtps2qqv2di<mask_name>"): Ditto.
(define_insn "<fixsuffix>fix_truncv2sfv2di2<mask_name>"): Ditto.
(define_insn "avx512f_<code>v8div16qi2_mask_store"): Ditto.
(define_insn "vec_set_hi_<mode><mask_name>"): Ditto.
(define_insn "<mask_codefor>avx512dq_broadcast<mode><mask_name>"):
Ditto.
(define_insn "*avx512f_gatherdi<mode>"): Ditto.
(define_insn "*avx512f_scatterdi<mode>"): Ditto.
* config/i386/i386.c (ix86_print_operand): Expand check for size
override codes for Intel syntax.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236362 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-18 Richard Biener <rguenther@suse.de>
rguenth [Wed, 18 May 2016 08:10:20 +0000 (08:10 +0000)] 
2016-05-18  Richard Biener  <rguenther@suse.de>

PR tree-optimization/71168
* tree-loop-distribution.c (distribute_loop): Move *destroy_p
initialization earlier.

* gcc.dg/torture/pr71168.c: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236361 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[Patch AArch64] Simplify reduc_plus_scal_v2[sd]f sequence
jgreenhalgh [Wed, 18 May 2016 08:00:33 +0000 (08:00 +0000)] 
[Patch AArch64] Simplify reduc_plus_scal_v2[sd]f sequence

gcc/

* config/aarch64/aarch64-simd.md
(aarch64_reduc_plus_internal<mode>): Rename to...
(reduc_plus_scal): ...This, and remove previous implementation.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236360 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoAdding the testcase which was not addaed as part of r236356.
kugan [Wed, 18 May 2016 07:50:05 +0000 (07:50 +0000)] 
Adding the testcase which was not addaed as part of r236356.
gcc/testsuite/ChangeLog:

2016-05-17  Kugan Vivekanandarajah  <kuganv@linaro.org>

PR middle-end/63586
* gcc.dg/tree-ssa/pr63586-2.c: New test.
* gcc.dg/tree-ssa/pr63586.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236359 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago2016-05-18 Richard Biener <rguenther@suse.de>
rguenth [Wed, 18 May 2016 07:41:09 +0000 (07:41 +0000)] 
2016-05-18  Richard Biener  <rguenther@suse.de>

* passes.def: Put late dse and cd_dce in canonical order.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236358 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * ipa-inline-transform.c (preserve_function_body_p): Look for
hubicka [Wed, 18 May 2016 07:12:46 +0000 (07:12 +0000)] 
* ipa-inline-transform.c (preserve_function_body_p): Look for
first non-thunk clone.
(save_function_body): Save into first non-thunk.
* lto-cgraph.c (lto_output_edge): When streaming thunk do not look
up call stmt id.
(lto_output_node): Inline thunks don't need body in every
partition.
* lto-streamer-in.c: Do not fixup thunk clones.
* cgraphclones.c (cgraph_node::create_edge_including_clone): Skip
thunks.
* tree-inline.c (copy_bb): Be prepared for target node to be new after
folding suceeds.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236357 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agogcc/testsuite/ChangeLog:
kugan [Wed, 18 May 2016 00:58:45 +0000 (00:58 +0000)] 
gcc/testsuite/ChangeLog:

2016-05-17  Kugan Vivekanandarajah  <kuganv@linaro.org>

PR middle-end/63586
* gcc.dg/tree-ssa/pr63586-2.c: New test.
* gcc.dg/tree-ssa/pr63586.c: New test.
* gcc.dg/tree-ssa/reassoc-14.c: Adjust multiplication count.

gcc/ChangeLog:

2016-05-17  Kugan Vivekanandarajah  <kuganv@linaro.org>

PR middle-end/63586
* tree-ssa-reassoc.c (transform_add_to_multiply): New.
(reassociate_bb): Call transform_add_to_multiply.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236356 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agogcc/ChangeLog:
kugan [Wed, 18 May 2016 00:46:58 +0000 (00:46 +0000)] 
gcc/ChangeLog:

2016-05-17  Kugan Vivekanandarajah  <kuganv@linaro.org>

* config/aarch64/aarch64.c (all_extensions): Removed unused static variable.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236355 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoDaily bump.
gccadmin [Wed, 18 May 2016 00:16:19 +0000 (00:16 +0000)] 
Daily bump.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236354 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * da.po: Update.
jsm28 [Wed, 18 May 2016 00:13:34 +0000 (00:13 +0000)] 
* da.po: Update.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236349 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * da.po, sv.po: Update.
jsm28 [Wed, 18 May 2016 00:10:15 +0000 (00:10 +0000)] 
* da.po, sv.po: Update.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236347 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * gcc.c-torture/execute/20030222-1.c: Skip on ptx.
nathan [Tue, 17 May 2016 21:28:11 +0000 (21:28 +0000)] 
* gcc.c-torture/execute/20030222-1.c: Skip on ptx.
* gcc.dg/pr68671.c: Fix ptx xfail-if.
* gcc.dg/torture/pr54261-1.c: Allocate atomic var statically.
* gcc.dg/torture/type-generic-1.c: Enable UNSAFE for ptx.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236346 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * config/nvptx/nvptx.c (nvptx_function_arg_boundary): New.
nathan [Tue, 17 May 2016 21:16:49 +0000 (21:16 +0000)] 
* config/nvptx/nvptx.c (nvptx_function_arg_boundary): New.
(TARGET_FUNCTION_ARG_BOUNDARY): Override.

testsuite/
* gcc.target/nvptx/abi-vararg-3.c: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236345 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFold bit_not through ASR and rotate
miyuki [Tue, 17 May 2016 20:50:22 +0000 (20:50 +0000)] 
Fold bit_not through ASR and rotate

gcc/

PR tree-optimization/54579
PR middle-end/55299
* match.pd (~(~X >> Y), ~(~X >>r Y), ~(~X <<r Y)): New patterns.

gcc/testsuite

PR tree-optimization/54579
PR middle-end/55299
* gcc.dg/fold-notrotate-1.c: New test.
* gcc.dg/fold-notshift-1.c: New test.
* gcc.dg/fold-notshift-2.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236344 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago PR ipa/71146
mpolacek [Tue, 17 May 2016 20:00:41 +0000 (20:00 +0000)] 
PR ipa/71146
* tree-inline.c (expand_call_inline): Call
maybe_remove_unused_call_args.

* g++.dg/ipa/pr71146.C: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236343 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agojit: gcc diagnostics are jit errors
dmalcolm [Tue, 17 May 2016 19:28:47 +0000 (19:28 +0000)] 
jit: gcc diagnostics are jit errors

libgccjit performs numerous checks at the API boundary, but
if these succeed, it ignores errors and other diagnostics emitted
within the core of gcc, and treats the compile of a gcc_jit_context
as having succeeded.

This patch ensures that if any diagnostics are emitted, they
are visible from the libgccjit API, and that the the context is
flagged as having failed.

For now any kind of diagnostic is treated as a jit error,
so warnings and notes also count as errors.

gcc/jit/ChangeLog:
* dummy-frontend.c: Include diagnostic.h.
(jit_begin_diagnostic): New function.
(jit_end_diagnostic): New function.
(jit_langhook_init): Register jit_begin_diagnostic
and jit_end_diagnostic with the global_dc.
* jit-playback.c: Include diagnostic.h.
(gcc::jit::playback::context::add_diagnostic): New method.
* jit-playback.h (struct diagnostic_context): Add forward
declaration.
(gcc::jit::playback::context::add_diagnostic): New method.

gcc/testsuite/ChangeLog:
* jit.dg/test-error-array-bounds.c: New test case.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236342 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agojit: document gcc_jit_context_new_call_through_ptr
dmalcolm [Tue, 17 May 2016 19:17:19 +0000 (19:17 +0000)] 
jit: document gcc_jit_context_new_call_through_ptr

gcc/jit/ChangeLog:
* docs/topics/expressions.rst (Function calls): Document
gcc_jit_context_new_call_through_ptr.
* docs/_build/texinfo/libgccjit.texi: Regenerate.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236341 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoFix minor doc bugs, signalling typo, major version changes rare.
wilson [Tue, 17 May 2016 18:50:22 +0000 (18:50 +0000)] 
Fix minor doc bugs, signalling typo, major version changes rare.

gcc/
* doc/cpp.texi (__GNUC__): Major version changes are no longer rare.
* doc/invoke.texi (-mnan=2008): Change signalling to signaling.
* doc/md.texi (fmin@var{m}3): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236340 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agox & C -> x if we know that x & ~C == 0
glisse [Tue, 17 May 2016 17:57:27 +0000 (17:57 +0000)] 
x & C -> x if we know that x & ~C == 0

2016-05-17  Marc Glisse  <marc.glisse@inria.fr>

gcc/
* match.pd (X & C): New transformation.

gcc/testsuite/
* gcc.dg/tree-ssa/and-1.c: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236338 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago~X & Y to X ^ Y in some cases
glisse [Tue, 17 May 2016 17:54:28 +0000 (17:54 +0000)] 
~X & Y to X ^ Y in some cases

2016-05-17  Marc Glisse  <marc.glisse@inria.fr>

gcc/
* match.pd (~X & Y): New transformation.

gcc/testsuite/
* gcc.dg/tree-ssa/pr69270.c: Adjust.
* gcc.dg/tree-ssa/andnot-1.c: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236337 138bc75d-0d04-0410-961f-82ee72b054a4

9 years agoVRP: range info of new variables
glisse [Tue, 17 May 2016 17:50:55 +0000 (17:50 +0000)] 
VRP: range info of new variables

2016-05-17  Marc Glisse  <marc.glisse@inria.fr>

gcc/
* tree-vrp.c (simplify_truth_ops_using_ranges): Set range
information for new SSA_NAME.
(simplify_conversion_using_ranges): Get range through get_range_info
instead of get_value_range.

gcc/testsuite/
* gcc.dg/tree-ssa/pr69270.c: Adjust.
* gcc.dg/tree-ssa/vrp99.c: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236336 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[AArch64, 4/4] Reimplement vmvn* intrinscis, remove inline assembly
jiwang [Tue, 17 May 2016 16:41:18 +0000 (16:41 +0000)] 
[AArch64, 4/4] Reimplement vmvn* intrinscis, remove inline assembly

gcc/
* config/aarch64/arm_neon.h (vmvn_s8): Reimplement using C operator.
Remove inline assembly.
(vmvn_s16): Likewise.
(vmvn_s32): Likewise.
(vmvn_u8): Likewise.
(vmvn_u16): Likewise.
(vmvn_u32): Likewise.
(vmvnq_s8): Likewise.
(vmvnq_s16): Likewise.
(vmvnq_s32): Likewise.
(vmvnq_u8): Likewise.
(vmvnq_u16): Likewise.
(vmvnq_u32): Likewise.
(vmvn_p8): Likewise.
(vmvnq_p16): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236334 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[AArch64, 3/4] Reimplement multiply by element to get rid of inline assembly
jiwang [Tue, 17 May 2016 16:39:39 +0000 (16:39 +0000)] 
[AArch64, 3/4] Reimplement multiply by element to get rid of inline assembly

gcc/
* config/aarch64/aarch64-simd.md (vmul_n_f32): Remove inline assembly.
Use builtin.
(vmul_n_s16): Likewise.
(vmul_n_s32): Likewise.
(vmul_n_u16): Likewise.
(vmul_n_u32): Likewise.
(vmulq_n_f32): Likewise.
(vmulq_n_f64): Likewise.
(vmulq_n_s16): Likewise.
(vmulq_n_s32): Likewise.
(vmulq_n_u16): Likewise.
(vmulq_n_u32): Likewise.

gcc/testsuite/
* gcc.target/aarch64/simd/vmul_elem_1.c: Use intrinsics.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236333 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[AArch64, 2/4] Extend vector mutiply by element to all supported modes
jiwang [Tue, 17 May 2016 16:37:19 +0000 (16:37 +0000)] 
[AArch64, 2/4] Extend vector mutiply by element to all supported modes

gcc/
* config/aarch64/aarch64-simd.md (*aarch64_mul3_elt_to_128df): Extend to
all supported modes.  Rename to "*aarch64_mul3_elt_from_dup".

gcc/testsuite/
* gcc.target/aarch64/simd/vmul_elem_1.c: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236332 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago[AArch64, 1/4] Add the missing support of vfms_n_f32, vfmsq_n_f32, vfmsq_n_f64
jiwang [Tue, 17 May 2016 16:34:46 +0000 (16:34 +0000)] 
[AArch64, 1/4]  Add the missing support of vfms_n_f32, vfmsq_n_f32, vfmsq_n_f64

gcc/
* config/aarch64/aarch64-simd.md (*aarch64_fma4_elt_to_128df): Rename
to *aarch64_fma4_elt_from_dup<mode>.
(*aarch64_fnma4_elt_to_128df): Rename to
*aarch64_fnma4_elt_from_dup<mode>.
* config/aarch64/arm_neon.h (vfma_n_f64): New.
(vfms_n_f32): Likewise.
(vfms_n_f64): Likewise.
(vfmsq_n_f32): Likewise.
(vfmsq_n_f64): Likewise.

gcc/testsuite/
* gcc.target/aarch64/fmla_intrinsic_1.c: Allow ".d[index]" besides
".2d[index]" when scan the assembly.
* gcc.target/aarch64/fmls_intrinsic_1.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/arm-neon-ref.h: New entry for
float64x1.
* gcc.target/aarch64/advsimd-intrinsics/vfms_vfma_n.c: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236331 138bc75d-0d04-0410-961f-82ee72b054a4

9 years ago * wide-int.h: Change fixed_wide_int_storage from class to struct.
gerald [Tue, 17 May 2016 14:56:45 +0000 (14:56 +0000)] 
* wide-int.h: Change fixed_wide_int_storage from class to struct.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@236324 138bc75d-0d04-0410-961f-82ee72b054a4