gcc.git
8 years agore PR libfortran/69799 (FAIL: gfortran.dg/coarray_allocate_3.f08 at -O1 and above)
John David Anglin [Tue, 15 Mar 2016 23:34:49 +0000 (23:34 +0000)]
re PR libfortran/69799 (FAIL: gfortran.dg/coarray_allocate_3.f08 at -O1 and above)

PR libfortran/69799
* gfortran.dg/coarray_allocate_5.f08: Add "-latomic" option if
libatomic_available.

From-SVN: r234240

8 years agoFix compiling large files
Richard Henderson [Tue, 15 Mar 2016 23:08:45 +0000 (16:08 -0700)]
Fix compiling large files

  * line-map.c (new_linemap): Make alloc_size a size_t.

From-SVN: r234239

8 years agoFix thinko in indirect_jump_optimize
Alan Modra [Tue, 15 Mar 2016 22:04:42 +0000 (08:34 +1030)]
Fix thinko in indirect_jump_optimize

PR rtl-optimization/69195
PR rtl-optimization/47992
* ira.c (indirect_jump_optimize): Ignore artificial defs.
Add comments.

From-SVN: r234235

8 years agore PR c++/70209 (ICE in strip_typedefs, at cp/tree.c:1377)
Marek Polacek [Tue, 15 Mar 2016 21:10:11 +0000 (21:10 +0000)]
re PR c++/70209 (ICE in strip_typedefs, at cp/tree.c:1377)

PR c++/70209
* tree.c (strip_typedefs): Call strip_typedefs again on the
DECL_ORIGINAL_TYPE result.

* g++.dg/ext/attribute-may-alias-4.C: New test.

From-SVN: r234234

8 years agore PR c++/70095 ([C++14] Link error on partially specialized variable template)
Jason Merrill [Tue, 15 Mar 2016 19:37:37 +0000 (15:37 -0400)]
re PR c++/70095 ([C++14] Link error on partially specialized variable template)

PR c++/70095
* pt.c (instantiate_decl): Fix call to variable_template_p.

From-SVN: r234231

8 years agoFix more P0184R0 references.
Jason Merrill [Tue, 15 Mar 2016 19:37:32 +0000 (15:37 -0400)]
Fix more P0184R0 references.

From-SVN: r234230

8 years agore PR c++/70141 (template parameter not deducible in partial specialization of templa...
Jason Merrill [Tue, 15 Mar 2016 19:21:44 +0000 (15:21 -0400)]
re PR c++/70141 (template parameter not deducible in partial specialization of template inside template)

PR c++/70141
* pt.c (for_each_template_parm_r): Always walk into TYPENAME_TYPE.

From-SVN: r234228

8 years agopr63384.C: Add -w to dg-options.
Alexander Monakov [Tue, 15 Mar 2016 18:11:14 +0000 (21:11 +0300)]
pr63384.C: Add -w to dg-options.

* g++.dg/pr63384.C: Add -w to dg-options.  Remove '-toggle'
in -fvar-tracking-assignments-toggle flag.

From-SVN: r234227

8 years agore PR middle-end/69513 (LTO bootstrap fails with bootstrap-profiled during linking...
Eric Botcazou [Tue, 15 Mar 2016 17:55:39 +0000 (17:55 +0000)]
re PR middle-end/69513 (LTO bootstrap fails with bootstrap-profiled during linking gnat1 in stagefeedback)

PR bootstrap/69513
* dwarf2out.c (flush_limbo_die_list): Really flush the limbo list.

From-SVN: r234226

8 years agoifcvt-4.c: Add -misel for powerpc*.
Pat Haugen [Tue, 15 Mar 2016 17:45:13 +0000 (17:45 +0000)]
ifcvt-4.c: Add -misel for powerpc*.

* gcc.dg/ifcvt-4.c: Add -misel for powerpc*.

From-SVN: r234224

8 years agoavr.md (rotl<mode>3): Set mode for operand 2.
Senthil Kumar Selvaraj [Tue, 15 Mar 2016 16:21:49 +0000 (16:21 +0000)]
avr.md (rotl<mode>3): Set mode for operand 2.

* config/avr/avr.md (rotl<mode>3): Set mode for operand 2.

From-SVN: r234223

8 years agore PR rtl-optimization/70222 (Test miscompiled with -O1)
Jakub Jelinek [Tue, 15 Mar 2016 16:11:48 +0000 (17:11 +0100)]
re PR rtl-optimization/70222 (Test miscompiled with -O1)

PR rtl-optimization/70222
* combine.c (simplify_shift_const_1): For A >> B >> C LSHIFTRT
optimization if mode is different from result_mode, queue up masking
of the result in outer_op.  Formatting fix.

* gcc.c-torture/execute/pr70222-1.c: New test.
* gcc.c-torture/execute/pr70222-2.c: New test.

From-SVN: r234222

8 years agore PR middle-end/70239 (ICE in ggc_set_mark)
Jakub Jelinek [Tue, 15 Mar 2016 16:10:59 +0000 (17:10 +0100)]
re PR middle-end/70239 (ICE in ggc_set_mark)

PR middle-end/70239
* tree-ssa-sccvn.c (VN_INFO_GET): Use safe_grow_cleared instead
of safe_grow.

From-SVN: r234221

8 years agoFix pr68714 test for targets not supporting V4SImode.
Richard Henderson [Tue, 15 Mar 2016 15:43:00 +0000 (08:43 -0700)]
Fix pr68714 test for targets not supporting V4SImode.

  * gcc.dg/tree-ssa/pr68714.c: Test during reassoc pass.

From-SVN: r234220

8 years agore PR rtl-optimization/69032 (ICE: in cfg_preds_1, at sel-sched-ir.c:4809 with -fsche...
Andrey Belevantsev [Tue, 15 Mar 2016 15:42:07 +0000 (18:42 +0300)]
re PR rtl-optimization/69032 (ICE: in cfg_preds_1, at sel-sched-ir.c:4809 with -fsched-pressure -fsel-sched-pipelining -fselective-scheduling)

gcc/

PR rtl-optimization/69032
* sel-sched-ir.c (get_seqno_by_preds): Include both insn and head when
looping backwards over basic block insns.

testsuite/

PR rtl-optimization/69032
* gcc.dg/pr69032.c: New test.

From-SVN: r234219

8 years agore PR target/66660 ([ia64] Speculative load not checked before use, leading to a...
Andrey Belevantsev [Tue, 15 Mar 2016 15:36:44 +0000 (18:36 +0300)]
re PR target/66660 ([ia64] Speculative load not checked before use, leading to a NaT Consumption Vector interruption)

        PR target/66660
        * sel-sched-ir.c (merge_expr): Avoid changing the speculative pattern
        to non-speculative when propagating trap bits.

From-SVN: r234218

8 years agore PR rtl-optimization/63384 (scheduler loops on endless fence list with -fselective...
Andrey Belevantsev [Tue, 15 Mar 2016 15:25:41 +0000 (18:25 +0300)]
re PR rtl-optimization/63384 (scheduler loops on endless fence list with -fselective-scheduling2 on x86)

gcc/

PR rtl-optimization/63384
* sel-sched.c (invoke_aftermath_hooks): Do not decrease issue_more
on DEBUG_INSN_P insns.

testsuite/

PR rtl-optimization/63384
* g++.dg/pr63384.C: New test.

From-SVN: r234217

8 years agore PR target/64411 (ICE: in verify_target_availability, at sel-sched.c:1577 with...
Andrey Belevantsev [Tue, 15 Mar 2016 15:13:29 +0000 (18:13 +0300)]
re PR target/64411 (ICE: in verify_target_availability, at sel-sched.c:1577 with -Os -mcmodel=medium -fPIC -fschedule-insns -fselective-scheduling)

gcc/

        PR target/64411
        * sched-deps.c (get_implicit_reg_pending_clobbers): New function,
        factored out from ...
        (sched_analyze_insn): ... here.
        * sched-int.h (get_implicit_reg_pending_clobbers): Declare it.
        * sel-sched-ir.c (setup_id_implicit_regs): New function, use
        get_implicit_reg_pending_clobbers in it.
        (setup_id_reg_sets): Use setup_id_implicit_regs.
        (deps_init_id): Ditto.

testsuite/

PR target/64411
* gcc.target/i386/pr64411.C: New test.

From-SVN: r234216

8 years agoAdd goacc/kernels-alias{,-2}.f95
Tom de Vries [Tue, 15 Mar 2016 13:01:51 +0000 (13:01 +0000)]
Add goacc/kernels-alias{,-2}.f95

2016-03-15  Tom de Vries  <tom@codesourcery.com>

* gfortran.dg/goacc/kernels-alias-2.f95: New test.
* gfortran.dg/goacc/kernels-alias.f95: New test.

From-SVN: r234214

8 years agoexpr.c (cpp_classify_number): Hex floats are new in C++1z.
Jason Merrill [Tue, 15 Mar 2016 12:08:31 +0000 (08:08 -0400)]
expr.c (cpp_classify_number): Hex floats are new in C++1z.

* libcpp/expr.c (cpp_classify_number): Hex floats are new in C++1z.

* libcpp/init.c (lang_defaults): Likewise.
* gcc/c-family/c-cppbuiltin.c (c_cpp_builtins): Set __cpp_hex_float.

From-SVN: r234213

8 years agofeat-cxx1z.C: Fix __cpp_fold_expressions value.
Jason Merrill [Tue, 15 Mar 2016 12:08:25 +0000 (08:08 -0400)]
feat-cxx1z.C: Fix __cpp_fold_expressions value.

* g++.dg/cpp1z/feat-cxx1z.C: Fix __cpp_fold_expressions value.
* g++.dg/cpp1z/fold7.C: Likewise.

From-SVN: r234212

8 years agoFix fdump-ipa-all-graph
Tom de Vries [Tue, 15 Mar 2016 11:51:32 +0000 (11:51 +0000)]
Fix fdump-ipa-all-graph

2016-03-15  Tom de Vries  <tom@codesourcery.com>

PR ipa/70161
* cgraph.c (cgraph_node::get_body): Save, reset and restore
dump_file_name.
* passes.c (execute_one_ipa_transform_pass): Add missing argument to
execute_function_dump.
(execute_one_pass): Don't dump function if it will be dumped after ipa
transform.

From-SVN: r234211

8 years agoPR c++/53792 - [C++11] improving compiler-time constexpr evaluation
Martin Sebor [Tue, 15 Mar 2016 03:05:17 +0000 (03:05 +0000)]
PR c++/53792 - [C++11] improving compiler-time constexpr evaluation

gcc/testsuite/ChangeLog:
2016-03-14  Martin Sebor  <msebor@redhat.com>

PR c++/53792
* g++.dg/cpp0x/constexpr-inline.C: New test.
* g++.dg/cpp0x/constexpr-inline-1.C: Same.

From-SVN: r234208

8 years ago* c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
Jason Merrill [Tue, 15 Mar 2016 02:57:52 +0000 (22:57 -0400)]
* c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.

From-SVN: r234207

8 years agogenrecog: Fix crash on invalid input
Segher Boessenkool [Tue, 15 Mar 2016 00:42:43 +0000 (01:42 +0100)]
genrecog: Fix crash on invalid input

If your machine description refers to a non-existent predicate genrecog
crashes.  This fixes it.

* genrecog.c (match_pattern_2): If pred is NULL don't call
safe_predicate_mode on it.

From-SVN: r234206

8 years agoDaily bump.
GCC Administrator [Tue, 15 Mar 2016 00:16:14 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r234205

8 years ago* gcc.dg/torture/pr70083.c: Prune non-standard ABI.
David Edelsohn [Mon, 14 Mar 2016 23:30:52 +0000 (23:30 +0000)]
* gcc.dg/torture/pr70083.c: Prune non-standard ABI.

From-SVN: r234202

8 years agore PR middle-end/70219 (ICE: in delete_move_and_clobber, at lra-constraints.c:5864...
Jakub Jelinek [Mon, 14 Mar 2016 22:19:32 +0000 (23:19 +0100)]
re PR middle-end/70219 (ICE: in delete_move_and_clobber, at lra-constraints.c:5864 with -O2)

PR middle-end/70219
* lra-constraints.c (delete_move_and_clobber): Change assertion
to also allow dregno == 0.

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

From-SVN: r234201

8 years agore PR tree-optimization/68714 (less folding of vector comparison)
Richard Henderson [Mon, 14 Mar 2016 20:48:15 +0000 (13:48 -0700)]
re PR tree-optimization/68714 (less folding of vector comparison)

PR tree-opt/68714

  * tree-ssa-reassoc.c (ovce_extract_ops, optimize_vec_cond_expr): New.
  (can_reassociate_p): Allow ANY_INTEGRAL_TYPE_P.
  (reassociate_bb): Use optimize_vec_cond_expr; avoid
  optimize_range_tests, attempt_builtin_copysign and attempt_builtin_powi
  on vectors.

From-SVN: r234196

8 years agoP08184R0: Generalizing the Range-Based For Loop
Casey Carter [Mon, 14 Mar 2016 19:57:54 +0000 (19:57 +0000)]
P08184R0: Generalizing the Range-Based For Loop

* parser.c (cp_convert_range_for): Set the type of __end separately.
(cp_parser_perform_range_for_lookup): Allow different begin/end
types if they are comparable.

Co-Authored-By: Jason Merrill <jason@redhat.com>
From-SVN: r234191

8 years agoLRA: identify biggest access mode for hard_regs and use it in split_reg
Bernd Schmidt [Mon, 14 Mar 2016 15:08:54 +0000 (15:08 +0000)]
LRA: identify biggest access mode for hard_regs and use it in split_reg

PR target/70083
* lra-lives.c (process_bb_lives): Also update biggest mode for hard
regs.
(lra_create_live_ranges_1): initialize hard register biggest_mode to
VOIDmode.
* lra-constraints.c (split_reg): For hard regs, try to find the
biggest single-register mode used in the function.

testsuite/
PR target/70083
* gcc.dg/torture/pr70083.c: New test.
* gcc.target/i386/pr70083.c: New test.

From-SVN: r234184

8 years agore PR tree-optimization/56365 (Missed opportunities for smin/smax standard name patte...
Richard Biener [Mon, 14 Mar 2016 14:50:40 +0000 (14:50 +0000)]
re PR tree-optimization/56365 (Missed opportunities for smin/smax standard name patterns when compiling as C++)

2016-03-14  Richard Biener  <rguenther@suse.de>

PR tree-optimization/56365
* tree-ssa-phiopt.c (minmax_replacement): Handle alternate
constants to compare against.

* gcc.dg/tree-ssa/phi-opt-14.c: New testcase.

From-SVN: r234183

8 years agors6000: Handle "d" output in the bd*z patterns (PR70098)
Segher Boessenkool [Mon, 14 Mar 2016 14:18:44 +0000 (15:18 +0100)]
rs6000: Handle "d" output in the bd*z patterns (PR70098)

In the rs6000 port, FLOAT_REGS can contain DImode values when compiling
for 64-bit targets.  Some instructions (like "fcfid" in the testcase,
convert from integer to DP float) only work on floating point registers.
So, we do want to allow DImode in these regs.

Now, in unusual cases IRA will assign FLOAT_REGS to some allocno where
some insns cannot handle FLOAT_REGS there, so they will need a reload.
Maybe IRA can be made smarter, but it isn't doing anything wrong here,
so we should be able to handle it.

The place it goes wrong is in the output of the *ctrdi_internal[1256]
pattern: the "bdz" and "bdnz" instructions.  GCC refuses to do output
reloads on JUMP_INSNs, probably because it is hard to do, needs different
strategies than "normal" reloads do, and it cannot even be done at all
for general patterns.  So JUMP_INSNs need to be able to handle every
possible output for the register class used.

These patterns already handle writing to "c" (the base insn case), and
to "r", "m", and "c" or "l"; all those via splitters.  We just need to
handle "d" as well.  That is what this patch does.  [A predicate in one
of the splitters needs to be touched up so that the correct splitter
is used for the FLOAT_REGS case.]

But, that leaves another problem.  One of the insns that are split to
is a move from a GPR to an FPR.  That work fine on targets with direct
move (which does exactly that), i.e. power8 and up.  But older targets
need memory to do the move, and this splitter runs after reload so
it cannot allocate memory; and allocating memory beforehand for every
bdnz insn is pretty horrible as well.

This patch implements the easy part.  With it, power8 works, where it
didn't before.

PR target/70098
* config/rs6000/rs6000.md (*ctr<mode>_internal1, *ctr<mode>_internal2,
*ctr<mode>_internal5, *ctr<mode>_internal6): Also allow "d" as output.
(define_split for the GPR case): Use int_reg_operand instead of
gpc_reg_operand for the output.

gcc/testsuite/
PR target/70098
* lib/target-supports.exp (check_effective_target_powerpc64_no_dm):
New function.
* g++.dg/pr70098.C: New testcase.

From-SVN: r234181

8 years agoUnshare create_empty_if_region_on_edge argument
Tom de Vries [Mon, 14 Mar 2016 09:19:14 +0000 (09:19 +0000)]
Unshare create_empty_if_region_on_edge argument

2016-03-14  Tom de Vries  <tom@codesourcery.com>

PR tree-optimization/70045
* graphite-isl-ast-to-gimple.c (graphite_create_new_loop_guard): Unshare
create_empty_if_region_on_edge argument.

* gcc.dg/graphite/pr70045.c: New test.

From-SVN: r234177

8 years agoSummary: libcc1: rerun configure when gcc/BASE-VER changes
Andreas Schwab [Mon, 14 Mar 2016 08:54:06 +0000 (08:54 +0000)]
Summary: libcc1: rerun configure when gcc/BASE-VER changes

* configure.ac (CONFIG_STATUS_DEPENDENCIES): Substitute.
* configure: Regenerate.
* Makefile.in: Regenerate.

From-SVN: r234176

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

From-SVN: r234175

8 years agovxworks.h (STACK_CHECK_STATIC_BUILTIN): Define.
Eric Botcazou [Sun, 13 Mar 2016 20:35:48 +0000 (20:35 +0000)]
vxworks.h (STACK_CHECK_STATIC_BUILTIN): Define.

* config/arm/vxworks.h (STACK_CHECK_STATIC_BUILTIN): Define.
(STACK_CHECK_PROTECT): Likewise.
* config/i386/vxworks.h (STACK_CHECK_STATIC_BUILTIN): Likewise
(STACK_CHECK_PROTECT): Likewise.
* config/rs6000/vxworks.h (STACK_CHECK_STATIC_BUILTIN): Likewise
(STACK_CHECK_PROTECT): Likewise.
* config/rs6000/vxworksae.h (STACK_CHECK_PROTECT): Likewise.
* config/sparc/vxworks.h (STACK_CHECK_STATIC_BUILTIN): Likewise.
(STACK_CHECK_PROTECT): Likewise.
ada/
* system-vxworks-m68k.ads (Stack_Check_Probes): Set to True.
(Stack_Check_Limits): Set to False.
* system-vxworks-mips.ads (Stack_Check_Probes): Set to True.
(Stack_Check_Limits): Set to False.
* system-vxworks-ppc.ads (Stack_Check_Probes): Set to True.
(Stack_Check_Limits): Set to False.
* system-vxworks-sparcv9.ads (Stack_Check_Probes): Set to True.
(Stack_Check_Limits): Set to False.
* system-vxworks-x86.ads (Stack_Check_Probes): Set to True.
(Stack_Check_Limits): Set to False.

From-SVN: r234171

8 years agolibgcc_s is required by libstdc++
Thomas Schwinge [Sun, 13 Mar 2016 19:08:21 +0000 (20:08 +0100)]
libgcc_s is required by libstdc++

libgomp/
* testsuite/lib/libgomp.exp (libgomp_init): Potentially append to
always_ld_library_path the path to libgcc_s.

From-SVN: r234170

8 years agore PR fortran/69043 (Trying to include a directory causes an infinite loop)
Jerry DeLisle [Sun, 13 Mar 2016 17:38:07 +0000 (17:38 +0000)]
re PR fortran/69043 (Trying to include a directory causes an infinite loop)

2016-03-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
    Jim MacArthur  <jim.macarthur@codethink.co.uk>

PR fortran/69043
* scanner.c (load_file): Check that included file is regular.

PR fortran/69043
* gfortran.dg/include_9.f90: New test.

Co-Authored-By: Jim MacArthur <jim.macarthur@codethink.co.uk>
From-SVN: r234169

8 years agore PR fortran/45076 ([OOP] gfortran.dg/dynamic_dispatch_6.f03 ICEs with -fprofile...
Dominique d'Humieres [Sun, 13 Mar 2016 09:48:20 +0000 (10:48 +0100)]
re PR fortran/45076 ([OOP] gfortran.dg/dynamic_dispatch_6.f03 ICEs with -fprofile-use)

2016-03-13  Dominique d'Humieres  <dominiq@lps.ens.fr>

PR fortran/45076
gfortran.dg/prof/prof.exp: New script.
gfortran.dg/prof/dynamic_dispatch_6.f03: New test.

From-SVN: r234168

8 years agore PR fortran/69520 (Implement reversal of -fcheck options)
Jerry DeLisle [Sun, 13 Mar 2016 00:19:08 +0000 (00:19 +0000)]
re PR fortran/69520 (Implement reversal of -fcheck options)

2016-03-12  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
    Harold Anlauf  <anlauf@gmx.de>

PR fortran/69520
* invoke.texi: Explain use of the 'no-' construct within the
-fcheck= option.
* options.c (gfc_handle_runtime_check_option): Enable use of
'no-' prefix for the various options with -fcheck= to allow
negating previously enabled check options.

Co-Authored-By: Harald Anlauf <anlauf@gmx.de>
From-SVN: r234167

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

From-SVN: r234166

8 years agore PR rtl-optimization/69307 (wrong code with -O2 -fselective-scheduling @ armv7a)
Andrey Belevantsev [Sat, 12 Mar 2016 17:12:29 +0000 (20:12 +0300)]
re PR rtl-optimization/69307 (wrong code with -O2 -fselective-scheduling @ armv7a)

PR rtl-optimization/69307
* sel-sched.c (choose_best_pseudo_reg): Properly check for hard
registers in modes that span more than one register.

PR rtl-optimization/69307
* gcc.dg/pr69307.c: New test.

From-SVN: r234163

8 years agore PR target/69614 (wrong code with -Os -fno-expensive-optimizations -fschedule-insns...
Vladimir Makarov [Sat, 12 Mar 2016 14:56:24 +0000 (14:56 +0000)]
re PR target/69614 (wrong code with -Os -fno-expensive-optimizations -fschedule-insns -mtpcs-leaf-frame -fira-algorithm=priority @ armv7a)

2016-03-12  Vladimir Makarov  <vmakarov@redhat.com>

PR target/69614
* lra-constraints.c (delete_move_and_clobber): New.
(remove_inheritance_pseudos): Use it.

2016-03-12  Vladimir Makarov  <vmakarov@redhat.com>

PR target/69614
* gcc.target/arm/pr69614.c: New.

From-SVN: r234162

8 years agore PR fortran/70031 (Error in recursive module subroutine declaration if declared...
Paul Thomas [Sat, 12 Mar 2016 13:59:10 +0000 (13:59 +0000)]
re PR fortran/70031 (Error in recursive module subroutine declaration if declared as "module recursive")

2016-03-12  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/70031
* decl.c (gfc_match_prefix): Treat the 'module' prefix in the
same way as the others, rather than fixing it to come last.
(gfc_match_function_decl, gfc_match_subroutine): After errors
in 'copy_prefix', emit them immediately in the case of module
procedures to prevent a later ICE.

PR fortran/69524
* decl.c (gfc_match_submod_proc): Permit 'module procedure'
declarations within the contains section of modules as well as
submodules.
* resolve.c (resolve_fl_procedure): Likewise.
*trans-decl.c (build_function_decl): Change the gcc_assert to
allow all forms of module procedure declarations within module
contains sections.

2016-03-12  Paul Thomas  <pault@gcc.gnu.org>

PR fortran/70031
* gfortran.dg/submodule_14.f08: New test

PR fortran/69524
* gfortran.dg/submodule_15.f08: New test

From-SVN: r234161

8 years agore PR ada/70017 (c52103x and c52104x test failure on s390x)
Eric Botcazou [Sat, 12 Mar 2016 11:32:54 +0000 (11:32 +0000)]
re PR ada/70017 (c52103x and c52104x test failure on s390x)

PR ada/70017
* calls.c (emit_library_call_value_1): Clear the ECF_NOTHROW flag if
the libcall is LCT_THROW.
* explow.c (probe_stack_range): Pass LCT_THROW to emit_library_call
for the checking routine.

From-SVN: r234160

8 years agoFix PR c++/70106 (type of parenthesized qualified-id has wrong cv-qualifiers)
Patrick Palka [Sat, 12 Mar 2016 02:05:17 +0000 (02:05 +0000)]
Fix PR c++/70106 (type of parenthesized qualified-id has wrong cv-qualifiers)

gcc/cp/ChangeLog:

PR c++/70106
* semantics.c (force_paren_expr): Just build a PAREN_EXPR when
processing_template_decl and EXPR is a SCOPE_REF.

gcc/testsuite/ChangeLog:

PR c++/70106
* g++.dg/cpp1y/paren3.C: New test.

From-SVN: r234159

8 years agoDaily bump.
GCC Administrator [Sat, 12 Mar 2016 00:16:15 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r234158

8 years agore PR target/70131 (PowerPC ISA 2.07 is inefficient at doint (float)(int)x.)
Michael Meissner [Sat, 12 Mar 2016 00:10:54 +0000 (00:10 +0000)]
re PR target/70131 (PowerPC ISA 2.07 is inefficient at doint (float)(int)x.)

[gcc]
2016-03-11  Michael Meissner  <meissner@linux.vnet.ibm.com>

PR target/70131
* config/rs6000/rs6000.md (round32<mode>2_fprs): Do not do the
optimization if we have direct move.
(roundu32<mode>2_fprs): Likewise.

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

PR target/70131
* gcc.target/powerpc/ppc-round2.c: New test.

From-SVN: r234155

8 years ago* sv.po: Update.
Joseph Myers [Sat, 12 Mar 2016 00:00:52 +0000 (00:00 +0000)]
* sv.po: Update.

From-SVN: r234153

8 years agore PR target/70123 (Miscompilation of cfitsio testcase on s390x-linux starting with...
Bernd Schmidt [Fri, 11 Mar 2016 22:38:41 +0000 (15:38 -0700)]
re PR target/70123 (Miscompilation of cfitsio testcase on s390x-linux starting with r222144)

PR target/70123
* lra-remat.c (operand_to_remat): Disallow hard regs in the value t
be rematerialized.
(reg_overlap_for_remat_p): Renamed from input_regno_present_p.
Arguments swapped.  All callers changed.  Take reg_renumber into
account, and Calculate and compare register ranges for hard regs.

PR target/70123
* gcc.dg/torture/pr70123.c: New test.

From-SVN: r234152

8 years agore PR tree-optimization/70190 (ICE (segfault) at -O2 and -O3 on x86_64-linux-gnu)
Jeff Law [Fri, 11 Mar 2016 22:32:11 +0000 (15:32 -0700)]
re PR tree-optimization/70190 (ICE (segfault) at -O2 and -O3 on x86_64-linux-gnu)

PR tree-optimization/70190
* tree-ssa-threadbackward.c (fsm_find_control_statement_thread_paths):
Handle cases where we can not extract the taken edge, even though we
found a constant value.

PR tree-optimization/70190
* gcc.c-torture/compile/pr70190.c: New test.

From-SVN: r234151

8 years agore PR tree-optimization/64058 (Performance degradation after r216304)
Jeff Law [Fri, 11 Mar 2016 21:07:31 +0000 (14:07 -0700)]
re PR tree-optimization/64058 (Performance degradation after r216304)

PR tree-optimization/64058
* tree-ssa-coalesce.c (struct coalesce_pair): Add new field INDEX.
(num_coalesce_pairs): Move up earlier in file.
(find_coalesce_pair): Initialize the INDEX field for each pair
discovered.
(compare_pairs): No longer sort on the elements in each pair.
Instead break ties with the index of the coalesce pair.

From-SVN: r234149

8 years agoWmisleading-indentation.c: add more test cases for PR c/68187
David Malcolm [Fri, 11 Mar 2016 19:54:43 +0000 (19:54 +0000)]
Wmisleading-indentation.c: add more test cases for PR c/68187

gcc/testsuite/ChangeLog:
PR c/68187
* c-c++-common/Wmisleading-indentation.c (test43_a): New test
case.
(test43_b): Likewise.
(test43_c): Likewise.
(test43_d): Likewise.
(test43_e): Likewise.
(test43_f): Likewise.
(test43_g): Likewise.
(test44_a): Likewise.
(test44_b): Likewise.
(test44_c): Likewise.
(test44_d): Likewise.
(test44_e): Likewise.

From-SVN: r234146

8 years agoWmisleading-indentation: add reproducer for PR c/70085
David Malcolm [Fri, 11 Mar 2016 19:48:49 +0000 (19:48 +0000)]
Wmisleading-indentation: add reproducer for PR c/70085

PR c/70085 reported a false-positive from -Wmisleading-indentation.

The warning was fixed by the fix for PR c/68187 (r233972), but it seems
worth capturing the reproducer for PR c/70085 as an additional test case,
as it's slightly different to those seen in PR c/68187.

gcc/testsuite/ChangeLog:
PR c/70085
* c-c++-common/Wmisleading-indentation.c (pr70085): New test case.

From-SVN: r234145

8 years ago[AArch64] Fix gcc.target/aarch64/vect-reduc-or_1.c for -mcpu=cortex-a57
Kyrylo Tkachov [Fri, 11 Mar 2016 15:36:03 +0000 (15:36 +0000)]
[AArch64] Fix gcc.target/aarch64/vect-reduc-or_1.c for -mcpu=cortex-a57

* gcc.target/aarch64/vect-reduc-or_1.c: Add -fno-vect-cost-model to
dg-options.

From-SVN: r234142

8 years ago[AArch64] PR target/70002: Make aarch64_set_current_function play nice with pragma...
Kyrylo Tkachov [Fri, 11 Mar 2016 15:27:24 +0000 (15:27 +0000)]
[AArch64] PR target/70002: Make aarch64_set_current_function play nice with pragma resetting

PR target/70002
* config/aarch64/aarch64-protos.h
(aarch64_save_restore_target_globals): New prototype.
* config/aarch64/aarch64-c.c (aarch64_pragma_target_parse):
Call the above when popping pragma.
* config/aarch64/aarch64.c (aarch64_save_restore_target_globals):
New function.
(aarch64_set_current_function): Rewrite using the above.

PR target/70002
PR target/69245
* gcc.target/aarch64/pr69245_2.c: New test.

From-SVN: r234141

8 years agore PR tree-optimization/70177 (ICE in extract_ops_from_tree starting with r233660)
Jakub Jelinek [Fri, 11 Mar 2016 12:28:50 +0000 (13:28 +0100)]
re PR tree-optimization/70177 (ICE in extract_ops_from_tree starting with r233660)

PR tree-optimization/70177
* gimple-expr.h (extract_ops_from_tree_1): Renamed to ...
(extract_ops_from_tree): ... this.  In the 2 argument
overload remove _1 suffix.
* gimple-expr.c (extract_ops_from_tree_1): Renamed to ...
(extract_ops_from_tree): ... this.
* gimple.c (gimple_build_assign, gimple_assign_set_rhs_from_tree):
Adjust callers.
* tree-ssa-loop-niter.c (derive_constant_upper_bound): Likewise.
* tree-ssa-forwprop.c (defcodefor_name): Call 3 operand
extract_ops_from_tree instead of 2 operand one.

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

From-SVN: r234140

8 years agoRe: Add -funconstrained-commons to work around PR/69368 (and others) in SPEC2006
Alan Lawrence [Fri, 11 Mar 2016 12:27:58 +0000 (12:27 +0000)]
Re: Add -funconstrained-commons to work around PR/69368 (and others) in SPEC2006

gcc/testsuite:

* gfortran.dg/unconstrained_commons.f: Widen regexp to match j_<N>.

From-SVN: r234139

8 years agoFix PR/70013
Alan Lawrence [Fri, 11 Mar 2016 12:08:01 +0000 (12:08 +0000)]
Fix PR/70013

gcc:

PR tree-optimization/70013
* tree-sra.c (analyze_access_subtree): Also set grp_unscalarized_data
for constant-pool entries.

gcc/testsuite:

* gcc.dg/tree-ssa/sra-20.c: New.

From-SVN: r234138

8 years agore PR rtl-optimization/70174 (ICE at -O1 and above on x86_64-linux-gnu in gen_lowpart...
Jakub Jelinek [Fri, 11 Mar 2016 12:07:01 +0000 (13:07 +0100)]
re PR rtl-optimization/70174 (ICE at -O1 and above on x86_64-linux-gnu in gen_lowpart_general, at rtlhooks.c:63)

PR rtl-optimization/70174
* expmed.c (store_bit_field_using_insv): Use gen_lowpart_if_possible
followed by gen_lowpart on force_reg instead of just gen_lowpart.

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

From-SVN: r234137

8 years agore PR tree-optimization/70169 (ICE at -O1 and above on x86_64-linux-gnu in gen_lsm_tm...
Jakub Jelinek [Fri, 11 Mar 2016 12:05:58 +0000 (13:05 +0100)]
re PR tree-optimization/70169 (ICE at -O1 and above on x86_64-linux-gnu in gen_lsm_tmp_name, at tree-ssa-loop.c:791)

PR tree-optimization/70169
* tree-ssa-loop.c (gen_lsm_tmp_name): Handle FUNCTION_DECL and
LABEL_DECL like VAR_DECL.  Emit nothing instead of gcc_unreachable
for unknown codes.

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

From-SVN: r234136

8 years agore PR rtl-optimization/70160 (gcc ICE at -O2 (seg fault) and above on valid code...
Ilya Enkovich [Fri, 11 Mar 2016 11:25:29 +0000 (11:25 +0000)]
re PR rtl-optimization/70160 (gcc ICE at -O2 (seg fault) and above on valid code on x86_64-linux-gnu)

gcc/

PR target/70160
* config/i386/i386.c (scalar_chain::convert_reg): Skip uses
of uninitialized values.

gcc/testsuite/

PR target/70160
* gcc.target/i386/pr70160.c: New test.

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

8 years agoS/390: Fix rounding for _Decimal128 to _Decimal32 conversion
Andreas Krebbel [Fri, 11 Mar 2016 07:47:47 +0000 (07:47 +0000)]
S/390: Fix rounding for _Decimal128 to _Decimal32 conversion

We do not have a direct conversion instruction from 128 bit DFP to 32
bit DFP so this needs to be done in two steps.  The first needs to be
done with the "prepare for shorter precision rounding mode" in order
to produce a correct result.

gcc/ChangeLog:

2016-03-11  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* config/s390/s390.md ("trunctddd2"): Turn former define_insn into
define_expand.
("*trunctddd2"): New pattern definition.
("trunctdsd2"): Set prep_for_short_prec rounding mode for the
TD->DD truncation.

gcc/testsuite/ChangeLog:

2016-03-11  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* gcc.target/s390/dfp-1.c: New test.

From-SVN: r234134

8 years agoS/390: Define macros for rounding mode constants
Andreas Krebbel [Fri, 11 Mar 2016 07:24:41 +0000 (07:24 +0000)]
S/390: Define macros for rounding mode constants

This patch replaces a few magic numbers used for floating point
rounding modes with macros.  This is mostly a NoOp change apart from:

fixuns_truncdddi2, fixuns_trunctddi2, fixuns_trunc<mode>si2: Replace 5
with DFP_RND_TOWARD_0 (which is 9).

5 as well as 9 represent round towards 0 with the difference that for
5 the new DFP quantum exception is enabled as well.  This exception
isn't IEEE754 and we do not have an interface to enable and test it
anyway.  So we do not intend to enable it.  This so far should not
have any noticable effect since the quantum exception was not
observable through the Posix functions.

Some pattern ("fix_trunc<mode>di2") is already using rounding mode 9
correctly.

gcc/ChangeLog:

2016-03-11  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* config/s390/s390.md (BFP_RND_*, DFP_RND_*): Add new constant
definitions for BFP and DFP rounding modes.
("fixuns_truncdddi2", "fixuns_trunctddi2")
("fixuns_trunc<BFP:mode><GPR:mode>2", "fixuns_trunc<mode>si2")
("fix_trunc<DSF:mode><GPR:mode>2", "fix_trunc<mode>di2")
("fix_trunctf<mode>2"): Use the new constants instead of magic
numbers.

From-SVN: r234133

8 years agoS/390: Rename shift_count_or_setmem_operand to setmem_operand
Andreas Krebbel [Fri, 11 Mar 2016 07:23:49 +0000 (07:23 +0000)]
S/390: Rename shift_count_or_setmem_operand to setmem_operand

The shift_count_or_setmem_operand predicate is now only used for
setmem patterns anymore.  Rename it together with the related
functions.

gcc/ChangeLog:

2016-03-11  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* config/s390/constraints.md: Adjust comment.
("Y"): Adjust comment.  Rename s390_decompose_shift_count to
s390_decompose_addrstyle_without_index.
* config/s390/predicates.md (shift_count_or_setmem_operand):
Rename to setmem_operand.
* config/s390/s390-protos.h
(s390_decompose_shift_count): Rename to
s390_decompose_addrstyle_without_index.
* config/s390/s390.c (s390_decompose_shift_count)
(s390_mem_constraint, print_shift_count_operand)
(print_operand_address, print_operand): Rename
s390_decompose_shift_count to
s390_decompose_addrstyle_without_index and rename
print_shift_count_operand to print_addrstyle_operand troughout the
file.
* config/s390/s390.md ("setmem_long_<P:mode>", "*setmem_long")
("*setmem_long_and", "*setmem_long_31z", "*setmem_long_and_31z"):
Rename shift_count_or_setmem_operand to setmem_operand.
* config/s390/vx-builtins.md ("vec_insert<mode>")
("vec_promote<mode>"): Replace shift_count_or_setmem_operand with
nonmemory_operand.

From-SVN: r234132

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

From-SVN: r234130

8 years agore PR target/70168 (Wrong code generation in __sync_val_compare_and_swap on PowerPC)
Ulrich Weigand [Thu, 10 Mar 2016 23:58:44 +0000 (23:58 +0000)]
re PR target/70168 (Wrong code generation in __sync_val_compare_and_swap on PowerPC)

PR target/70168
* config/rs6000/rs6000.c (rs6000_expand_atomic_compare_and_swap):
Handle overlapping retval and newval.

From-SVN: r234126

8 years agore PR testsuite/70009 (test case libgomp.oacc-c-c++-common/vprop.c fails starting...
Cesar Philippidis [Thu, 10 Mar 2016 22:50:40 +0000 (14:50 -0800)]
re PR testsuite/70009 (test case libgomp.oacc-c-c++-common/vprop.c fails starting with its introduction in r233607)

libgomp/
PR testsuite/70009
* testsuite/libgomp.oacc-c-c++-common/vprop.c: Make test data signed.

From-SVN: r234124

8 years ago* g++.dg/ubsan/pr70135.C: Don't rely on C++17 static_assert.
Jason Merrill [Thu, 10 Mar 2016 20:19:47 +0000 (15:19 -0500)]
* g++.dg/ubsan/pr70135.C: Don't rely on C++17 static_assert.

From-SVN: r234120

8 years agore PR target/7044 (vax casesi breakage)
Nick Clifton [Thu, 10 Mar 2016 17:24:16 +0000 (17:24 +0000)]
re PR target/7044 (vax casesi breakage)

PR target/7044
* config/aarch64/aarch64.c
(aarch64_override_options_after_change_1): When forcing
flag_omit_frame_pointer to be true, use a special value that can
be detected if this function is called again, thus preventing
flag_omit_leaf_frame_pointer from being forced to be false.

* gcc.target/aarch64/pr70044.c: New test.

From-SVN: r234118

8 years agore PR c++/70001 (Infinity compilation time)
Patrick Palka [Thu, 10 Mar 2016 17:23:06 +0000 (17:23 +0000)]
re PR c++/70001 (Infinity compilation time)

PR c++/70001
* constexpr.c (cxx_eval_vec_init_1): For pre_init case, reuse
return value from cxx_eval_constant_expression from earlier
elements if it is valid constant initializer requiring no
relocations.

* g++.dg/cpp0x/constexpr-70001-1.C: New test.
* g++.dg/cpp0x/constexpr-70001-2.C: New test.
* g++.dg/cpp0x/constexpr-70001-3.C: New test.

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

8 years ago[AArch64] Fix thinko in handling of -momit-leaf-frame-pointer option
Kyrylo Tkachov [Thu, 10 Mar 2016 16:24:26 +0000 (16:24 +0000)]
[AArch64] Fix thinko in handling of -momit-leaf-frame-pointer option

* common/config/aarch64/aarch64-common.c (aarch64_handle_option):
Set x_flag_omit_leaf_frame_pointer when handling
-momit-leaf-frame-pointer.

From-SVN: r234116

8 years agore PR ipa/69589 (ICE in initialize_node_lattices, at ipa-cp.c:971)
Jan Hubicka [Thu, 10 Mar 2016 16:11:14 +0000 (17:11 +0100)]
re PR ipa/69589 (ICE in initialize_node_lattices, at ipa-cp.c:971)

PR lto/69589
* cgraph.c (cgraph_node::dump): Dump split_part and indirect_call_target.
* cgraph.h (cgraph_node): Add indirect_call_target flag.
* ipa.c (has_addr_references_p): Cleanup.
(is_indirect_call_target_p): New.
(walk_polymorphic_call_targets): Do not mark virtuals that may be
called indirectly as local.
(symbol_table::remove_unreachable_nodes): Compute indirect_call_target.

* g++.dg/lto/pr69589_0.C: New testcase
* g++.dg/lto/pr69589_1.C: New testcase

From-SVN: r234115

8 years agore PR lto/69630 (LTO ICE in types_same_for_odr at ipa-devirt.c:402)
Jan Hubicka [Thu, 10 Mar 2016 16:05:59 +0000 (17:05 +0100)]
re PR lto/69630 (LTO ICE in types_same_for_odr at ipa-devirt.c:402)

PR ipa/69630
* ipa-devirt.c (possible_polymorphic_call_targets): Do not ICE
on cxa_pure_virtual.

From-SVN: r234114

8 years agore PR ipa/69589 (ICE in initialize_node_lattices, at ipa-cp.c:971)
Jan Hubicka [Thu, 10 Mar 2016 16:02:55 +0000 (17:02 +0100)]
re PR ipa/69589 (ICE in initialize_node_lattices, at ipa-cp.c:971)

PR lto/69589
* tree.c (free_lang_data_in_decl): Clear visibility of TYPE_DECL.

From-SVN: r234113

8 years agore PR ipa/69589 (ICE in initialize_node_lattices, at ipa-cp.c:971)
Jan Hubicka [Thu, 10 Mar 2016 16:02:00 +0000 (17:02 +0100)]
re PR ipa/69589 (ICE in initialize_node_lattices, at ipa-cp.c:971)

PR lto/69589
* tree.c (need_assembler_name_p): Only record main variant type names.

From-SVN: r234112

8 years agore PR c++/70153 (ICE on valid C++ code)
Marek Polacek [Thu, 10 Mar 2016 15:13:01 +0000 (15:13 +0000)]
re PR c++/70153 (ICE on valid C++ code)

PR c++/70153
* cp-gimplify.c (cp_fold): Handle UNARY_PLUS_EXPR.

* g++.dg/delayedfold/unary-plus1.C: New test.

From-SVN: r234111

8 years agopr45701-1.c: Escape brackets.
Andre Vieira [Thu, 10 Mar 2016 13:43:29 +0000 (13:43 +0000)]
pr45701-1.c: Escape brackets.

2016-03-10 Andre Vieira <andre.simoesdiasvieira@arm.com>

    gcc/testsuite/
    * gcc.target/arm/pr45701-1.c: Escape brackets.
    * gcc.target/arm/pr45701-2.c: Likewise.

From-SVN: r234109

8 years agore PR target/70113 ([AArch64] -mpc-relative-literal-loads conflicts with fix-cortex...
Christophe Lyon [Thu, 10 Mar 2016 13:29:48 +0000 (13:29 +0000)]
re PR target/70113 ([AArch64] -mpc-relative-literal-loads conflicts with fix-cortex-a53-843419)

2016-03-10  Christophe Lyon  <christophe.lyon@linaro.org>

PR target/70113.
* config/aarch64/aarch64.h (TARGET_FIX_ERR_A53_843419_DEFAULT):
Always define to 0 or 1.
(TARGET_FIX_ERR_A53_843419): New macro.
* config/aarch64/aarch64-elf-raw.h
(TARGET_FIX_ERR_A53_843419_DEFAULT): Update for above changes.
* config/aarch64/aarch64-linux.h: Likewise.
* config/aarch64/aarch64.c
(aarch64_override_options_after_change_1): Do not default
aarch64_nopcrelative_literal_loads to true if Cortex-A53 erratum
843419 is on.
(aarch64_attributes): Handle fix-cortex-a53-843419.
(aarch64_can_inline_p): Likewise.
* config/aarch64/aarch64.opt (aarch64_fix_a53_err843419): Save.

From-SVN: r234108

8 years agoAdd -funconstrained-commons to work around PR/69368 (and others) in SPEC2006
Alan Lawrence [Thu, 10 Mar 2016 12:19:45 +0000 (12:19 +0000)]
Add -funconstrained-commons to work around PR/69368 (and others) in SPEC2006

gcc/:

        * common.opt (funconstrained-commons, flag_unconstrained_commons): New.
        * tree.c (array_at_struct_end_p): Do not limit to size of decl for
        DECL_COMMONS if flag_unconstrained_commons is set.
        * tree-dfa.c (get_ref_base_and_extent): Likewise.
        * doc/invoke.texi (Optimize Options): Add -funconstrained-commons.
        (funconstrained-commons): Document.

gcc/testsuite:

* gfortran.dg/unconstrained_commons.f: New.

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

8 years agot-aarch64 (OPTIONS_H_EXTRA): Add aarch64-fusion-pairs.def and aarch64-tuning-flags.def
Christophe Lyon [Thu, 10 Mar 2016 12:03:25 +0000 (12:03 +0000)]
t-aarch64 (OPTIONS_H_EXTRA): Add aarch64-fusion-pairs.def and aarch64-tuning-flags.def

2016-03-10  Christophe Lyon  <christophe.lyon@linaro.org>

* config/aarch64/t-aarch64 (OPTIONS_H_EXTRA): Add
aarch64-fusion-pairs.def and aarch64-tuning-flags.def

From-SVN: r234105

8 years agotree-vect-stmts.c (vectorizable_mask_load_store): Check mask has a proper number...
Ilya Enkovich [Thu, 10 Mar 2016 10:58:57 +0000 (10:58 +0000)]
tree-vect-stmts.c (vectorizable_mask_load_store): Check mask has a proper number of elements.

gcc/

* tree-vect-stmts.c (vectorizable_mask_load_store): Check mask
has a proper number of elements.

From-SVN: r234104

8 years agoPR69195, Reload confused by invalid reg_equiv
Alan Modra [Thu, 10 Mar 2016 10:47:13 +0000 (21:17 +1030)]
PR69195, Reload confused by invalid reg_equiv

Optimizing indirect jumps to direct jumps, and deleting dead insns can
lead to changes in register lifetimes, which in turn can result in bad
reg_equiv info being passed to reload.  So do these tasks before
calculating reg_equiv info.

gcc/
PR rtl-optimization/69195
PR rtl-optimization/47992
* ira.c (recorded_label_ref): Delete.
(update_equiv_regs): Return void.
(indirect_jump_optimize): New function.
(ira): Call indirect_jump_optimize and delete_trivially_dead_insns
before regstat_compute_ri.  Don't rebuild_jump_labels here.
Delete update_regstat.
gcc/testsuite/
* gcc.dg/pr69195.c: New.
* gcc.dg/pr69238.c: New.

From-SVN: r234101

8 years agoXfail pr46032.c scan if alignment requirements not met
Tom de Vries [Thu, 10 Mar 2016 08:37:01 +0000 (08:37 +0000)]
Xfail pr46032.c scan if alignment requirements not met

2016-03-10  Tom de Vries  <tom@codesourcery.com>

PR testsuite/68915
* gcc.dg/vect/pr46032.c: Xfail scan if alignment requirements not met.

From-SVN: r234100

8 years agore PR tree-optimization/70128 (Linux kernel div patching optimized away)
Richard Biener [Thu, 10 Mar 2016 08:06:03 +0000 (08:06 +0000)]
re PR tree-optimization/70128 (Linux kernel div patching optimized away)

2016-03-10  Richard Biener  <rguenther@suse.de>

PR tree-optimization/70128
* tree-ssa-structalias.c (set_uids_in_ptset): Set
vars_contains_nonlocal for any FUNCTION_DECL or LABEL_DECL.

* gcc.dg/tree-ssa/alias-34.c: New testcase.
* gcc.dg/tree-ssa/alias-35.c: Likewise.

From-SVN: r234099

8 years agoDaily bump.
GCC Administrator [Thu, 10 Mar 2016 00:16:15 +0000 (00:16 +0000)]
Daily bump.

From-SVN: r234097

8 years agore PR tree-optimization/70152 (gcc ICE at -O3 and above on valid code on x86_64-linux...
Jakub Jelinek [Wed, 9 Mar 2016 20:12:19 +0000 (21:12 +0100)]
re PR tree-optimization/70152 (gcc ICE at -O3 and above on valid code on x86_64-linux-gnu in "replace_uses_by")

PR tree-optimization/70152
* tree-sra.c (replace_removed_params_ssa_names): Copy over
SSA_NAME_OCCURS_IN_ABNORMAL_PHI from old_name to new_name.

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

From-SVN: r234092

8 years agore PR target/70086 (ICE: in extract_constrain_insn_cached, at recog.c:2202 (insn...
Jakub Jelinek [Wed, 9 Mar 2016 20:06:59 +0000 (21:06 +0100)]
re PR target/70086 (ICE: in extract_constrain_insn_cached, at recog.c:2202 (insn does not satisfy its constraints) with -mavx512vl -ffloat-store)

PR target/70086
* config/i386/i386.md (truncdfsf2 splitter): Use gen_vec_concatv2df
instead of gen_sse2_loadlpd.
* config/i386/sse.md (*vec_concatv2df): Rename to...
(vec_concatv2df): ... this.

* gcc.target/i386/pr70086-1.c: New test.
* gcc.target/i386/pr70086-2.c: New test.
* gcc.target/i386/pr70086-3.c: New test.

From-SVN: r234091

8 years agore PR middle-end/70127 (wrong code on x86_64-linux-gnu at -O3 in 32-bit and 64-bit...
Jakub Jelinek [Wed, 9 Mar 2016 20:05:40 +0000 (21:05 +0100)]
re PR middle-end/70127 (wrong code on x86_64-linux-gnu at -O3 in 32-bit and 64-bit modes)

PR tree-optimization/70127
* fold-const.c (operand_equal_p): Revert the 2015-10-28 change.

* gcc.c-torture/execute/pr70127.c: New test.

From-SVN: r234090

8 years agoc-parser.c (c_parser_oacc_loop): Update cclauses and clauses when calling c_finish_om...
Cesar Philippidis [Wed, 9 Mar 2016 19:39:53 +0000 (11:39 -0800)]
c-parser.c (c_parser_oacc_loop): Update cclauses and clauses when calling c_finish_omp_clauses.

gcc/c/
* c-parser.c (c_parser_oacc_loop): Update cclauses and clauses
when calling c_finish_omp_clauses.

gcc/cp/
* parser.c (cp_parser_oacc_loop): Update cclauses and clauses
when calling c_finish_omp_clauses.

gcc/testsuite/
* c-c++-common/goacc/combined-directives-2.c: New test.

From-SVN: r234089

8 years agoPR c++/70105: prevent nonsensical underline spew for macro expansions
David Malcolm [Wed, 9 Mar 2016 18:23:27 +0000 (18:23 +0000)]
PR c++/70105: prevent nonsensical underline spew for macro expansions

diagnostic_show_locus can sometimes do the wrong thing when handling
expressions built up from macros.

PR c++/70105 (currently marked as a P3 regression) has an example of
a diagnostic where over 500 lines of irrelevant source are printed,
and underlined, giving >1000 lines of useless spew to stderr.

This patch adds extra sanitization to diagnostic-show-locus.c, so that
we only attempt to print underlines and secondary locations if such
locations are "sufficiently sane" relative to the primary location
of a diagnostic.

This "sufficiently sane" condition is implemented by a new helper
function compatible_locations_p, which requires such locations to
have the same macro expansion hierarchy as the primary location,
using linemap_macro_map_loc_unwind_toward_spelling, effectively
mimicing the expansion performed by LRK_SPELLING_LOCATION.

This may be too strong a condition, but it effectively fixes
PR c++/70105, without removing any underlines in my testing.

Successfully bootstrapped&regrtested in combination with the previous
patch on x86_64-pc-linux-gnu; adds 15 new PASS results to g++.sum
and 4 new PASS results to gcc.sum.

gcc/ChangeLog:
PR c/68473
PR c++/70105
* diagnostic-show-locus.c (compatible_locations_p): New function.
(layout::layout): Sanitize ranges using compatible_locations_p.

gcc/testsuite/ChangeLog:
PR c/68473
PR c++/70105
* g++.dg/diagnostic/pr70105.C: New test.
* gcc.dg/plugin/diagnostic-test-expressions-1.c (foo): New decl.
(test_multiple_ordinary_maps): New test function.

libcpp/ChangeLog:
PR c/68473
PR c++/70105
* line-map.c (linemap_macro_map_loc_unwind_toward_spelling): Move
decl...
* include/line-map.h
(linemap_macro_map_loc_unwind_toward_spelling): ...here,
converting from static to extern.

From-SVN: r234088

8 years agoPR c++/70105: Defer location expansion until diagnostic_show_locus
David Malcolm [Wed, 9 Mar 2016 18:14:43 +0000 (18:14 +0000)]
PR c++/70105: Defer location expansion until diagnostic_show_locus

gcc/ChangeLog:
PR c/68473
PR c++/70105
* diagnostic-show-locus.c (layout_range::layout_range): Replace
location_range param with three const expanded_locations * and a
bool.
(layout::layout): Replace call to
rich_location::lazily_expand_location with get_expanded_location.
Extract the range and perform location expansion here, passing
the results to the layout_range ctor.
* diagnostic.c (source_range::debug): Delete.
* diagnostic.h (diagnostic_expand_location): Reimplement in terms
of rich_location::get_expanded_location.
* gcc-rich-location.c (get_range_for_expr): Delete.
(gcc_rich_location::add_expr): Reimplement to avoid the
rich_location::add_range overload that took a location_range,
passing a location_t instead.

gcc/testsuite/ChangeLog:
PR c/68473
PR c++/70105
* gcc.dg/plugin/diagnostic_plugin_show_trees.c (show_tree):
Drop range information from call to inform_at_rich_loc.
* gcc.dg/plugin/diagnostic_plugin_test_show_locus.c (add_range):
New.
(test_show_locus): Replace calls to rich_location::add_range with
calls to add_range.  Rewrite the tests that used the now-defunct
rich_location ctor taking a source_range.  Simplify other tests
by replacing calls to COMBINE_LOCATION_DATA with calls to
make_location.

libcpp/ChangeLog:
PR c/68473
PR c++/70105
* include/line-map.h (source_range::debug): Delete.
(struct location_range): Update comment.  Replace
expanded_location fields "m_start", "m_finish", and "m_caret" with
a source_location field: "m_loc".
(class rich_location): Reword comment.
(rich_location::get_loc): Reimplement in terms of a new overloaded
variant which takes an unsigned int.
(rich_location::get_loc_addr): Delete.
(rich_location::add_range): Drop params "start" and "finish" in
favor of param "loc".  Drop overloaded variants taking a
source_range or location_range *.
(rich_location::lazily_expand_location): Delete in favor of...
(rich_location::get_expanded_location): New decl.
(rich_location::m_loc): Delete field.
(rich_location::m_column_override): New field.
* line-map.c (rich_location::rich_location):  Drop name of
line_maps * param.  Update initializations for deletion of field
"m_loc" and addition of field "m_column_override".  Reimplement
body as a call to add_range.  Delete overloaded variant taking a
source_range.
(rich_location::get_loc): New function.
(rich_location::lazily_expand_location): Delete in favor of...
(rich_location::get_expanded_location): New function.
(rich_location::override_column): Reimplement.
(rich_location::add_range): Drop params "start" and "finish" in
favor of param "loc".  Eliminate location expansion in favor of
simply storing loc.  Drop overloaded variants taking a
source_range or location_range *.
(rich_location::set_range): Eliminate location expansion.

From-SVN: r234087

8 years agore PR tree-optimization/70138 (wrong code at -O3 on x86_64-linux-gnu)
Richard Biener [Wed, 9 Mar 2016 16:41:19 +0000 (16:41 +0000)]
re PR tree-optimization/70138 (wrong code at -O3 on x86_64-linux-gnu)

2016-03-09  Richard Biener  <rguenther@suse.de>
Jakub Jelinek  <jakub@redhat.com>

PR tree-optimization/70138
* tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer):
Also skip vect_double_reduction_def.

* gcc.dg/vect/pr70138-1.c: New testcase.
* gcc.dg/vect/pr70138-2.c: Likewise.

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

8 years agore PR target/70049 (Error: operand size mismatch for `vpextrw' (wrong assembly genera...
Jakub Jelinek [Wed, 9 Mar 2016 14:10:58 +0000 (15:10 +0100)]
re PR target/70049 (Error: operand size mismatch for `vpextrw' (wrong assembly generated) with -masm=intel)

PR target/70049
* config/i386/sse.md (*vec_extract<mode>): Use %0 instead of %k0
if the operand is "m".

* gcc.target/i386/pr70049.c: New test.

From-SVN: r234085

8 years agore PR c/70143 (false strict-aliasing warning)
Richard Biener [Wed, 9 Mar 2016 14:01:16 +0000 (14:01 +0000)]
re PR c/70143 (false strict-aliasing warning)

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

c-family/
PR c/70143
* c-common.c (strict_aliasing_warning): Add back
alias_sets_conflict_p check.

* gcc.dg/Wstrict-aliasing-bogus-upcast.c: New testcase.
* gcc.dg/Wstrict-aliasing-struct-with-char-member.c: Likewise.
* gcc.dg/Wstrict-aliasing-struct-member.c: Remove again.

From-SVN: r234084

8 years ago* config/nvptx/nvptx.c (nvptx_option_override): Don't kill debug level.
Nathan Sidwell [Wed, 9 Mar 2016 13:33:03 +0000 (13:33 +0000)]
* config/nvptx/nvptx.c (nvptx_option_override): Don't kill debug level.

From-SVN: r234083

8 years agoReally don't xfail gcc.dg/vect/bb-slp-34.c on aarch64, arm
Rainer Orth [Wed, 9 Mar 2016 13:09:02 +0000 (13:09 +0000)]
Really don't xfail gcc.dg/vect/bb-slp-34.c on aarch64, arm

* gcc.dg/vect/bb-slp-34.c: Really don't xfail on aarch64-*-*,
arm-*-*.

From-SVN: r234081

8 years agore PR target/67278 (ICE: verify_gimple failed on darwin 14.5 x86_64)
Jakub Jelinek [Wed, 9 Mar 2016 09:23:53 +0000 (10:23 +0100)]
re PR target/67278 (ICE: verify_gimple failed on darwin 14.5 x86_64)

PR middle-end/67278
* gcc.dg/simd-7.c: Add -w -Wno-psabi to dg-options.

From-SVN: r234080

8 years agore PR target/67278 (ICE: verify_gimple failed on darwin 14.5 x86_64)
Jakub Jelinek [Wed, 9 Mar 2016 09:20:18 +0000 (10:20 +0100)]
re PR target/67278 (ICE: verify_gimple failed on darwin 14.5 x86_64)

PR target/67278
* gcc.dg/simd-8.c: Add -w -Wno-psabi to dg-options.

PR middle-end/70050
* gcc.dg/pr70050.c: Add -w to dg-options.  Fix up PR number
in testcase comment.

From-SVN: r234079