144836 Commits

Author SHA1 Message Date
Jeff Law
4a276c32c1 re PR rtl-optimization/70224 (ICE: RTL flag check: CROSSING_JUMP_P used with unexpected rtx code 'insn' in relax_delay_slots, at reorg.c:3310)
PR rtl-optimization/70024
	* reorg.c (relax_delay_slots): Pass right argument to CROSSING_JUMP_P.

From-SVN: r234262
2016-03-16 10:58:12 -06:00
Richard Henderson
aa43616c59 re PR middle-end/70199 (Crash at -O2 when using labels.)
PR middle-end/70199

 * function.h (struct function): Add has_forced_label_in_static.
 * gimplify.c (force_labels_r): Set it.
 * lto-streamer-in.c (input_struct_function_base): Read it.
 * lto-streamer-out.c (output_struct_function_base): Write it.
 * tree-inline.c (has_label_address_in_static_1): Remove.
 (copy_forbidden): Remove fndecl parameter; test
 has_forced_label_in_static.
 (inline_forbidden_p): Update call to copy_forbidden.
 (tree_versionable_function_p): Likewise.
 * ipa-chkp.c (chkp_instrumentable_p): Likewise.
 (chkp_versioning): Likewise.
 * tree-inline.h (copy_forbidden): Update decl.

testsuite/
 * gcc.c-torture/compile/pr70199.c: New.

From-SVN: r234261
2016-03-16 09:50:18 -07:00
H.J. Lu
59608fe587 Run dos2unix on gcc.dg/uninit-19.c
* gcc.dg/uninit-19.c: Run dos2unix.

From-SVN: r234260
2016-03-16 09:14:34 -07:00
Marek Polacek
ab4c578f0c re PR c/70093 (Instancing function with VM return type cases internal compiler error in 'assign_stack_temp_for_type'.)
PR c/70093
	* c-typeck.c (build_function_call_vec): Create a TARGET_EXPR for
	nested functions returning VM types.

	* cgraphunit.c (cgraph_node::expand_thunk): Also build call to the
	function being thunked if the result type doesn't have fixed size.
	* gimplify.c (gimplify_modify_expr): Also set LHS if the result type
	doesn't have fixed size.

	* gcc.dg/nested-func-10.c: New test.
	* gcc.dg/nested-func-9.c: New test.

From-SVN: r234259
2016-03-16 15:51:47 +00:00
Jakub Jelinek
f5387e76b7 re PR tree-optimization/68714 (less folding of vector comparison)
PR tree-optimization/68714
	* gcc.dg/tree-ssa/pr68714.c: Add -w -Wno-psabi to dg-options.

From-SVN: r234258
2016-03-16 14:34:36 +01:00
Thomas Schwinge
ee2e7d5147 Nowadays, we use plain -fopenacc to enable OpenACC kernels processing
libgomp/
	* testsuite/libgomp.oacc-fortran/kernels-loop-2.f95: Adjust to
	-ftree-parallelize-loops/-fopenacc changes.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-2.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-enter-exit-2.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-enter-exit.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-update.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data.f95: Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop.f95: Likewise.

From-SVN: r234257
2016-03-16 14:10:20 +01:00
Rainer Orth
a5046f48b3 Save call-clobbered registers in _mcount on 32-bit Solaris/x86 (PR target/38239)
PR target/38239
	* config/sol2/gmon.c [__i386__] (_mcount): Save and restore
	call-clobbered registers.
	(internal_mcount): Remove __i386__ handling.

From-SVN: r234256
2016-03-16 11:57:02 +00:00
Andreas Schwab
197adb6983 Summary: boehm-gc: add support for aarch64 ILP32
* include/private/gcconfig.h [AARCH64] (ALIGNMENT, CPP_WORDSZ):
Define for __ILP32__.

From-SVN: r234255
2016-03-16 11:44:36 +00:00
Bin Cheng
446fd64280 tree-vect-loop.c (vect_analyze_loop_2): Fix wrong dump info by reporting malformed loop nest.
* tree-vect-loop.c (vect_analyze_loop_2): Fix wrong dump info by
	reporting malformed loop nest.

From-SVN: r234254
2016-03-16 10:57:34 +00:00
Tom de Vries
448476ff53 Safely use nodes[0] in possible_polymorphic_call_targets
2016-03-16  Tom de Vries  <tom@codesourcery.com>

	PR lto/70187
	* ipa-devirt.c (possible_polymorphic_call_targets): Move
	nodes.length () == 1 test to before first nodes[0] access.

From-SVN: r234253
2016-03-16 10:21:27 +00:00
Svante Signell
b462f86075 Makefile.in: Add support for x86 GNU/Hurd.
* gcc-interface/Makefile.in: Add support for x86 GNU/Hurd.
	* s-osinte-gnu.ads: New file.

From-SVN: r234252
2016-03-16 10:04:01 +00:00
Tom de Vries
7662b718e1 Add missing single_pred_p test in scop_detection::merge_sese
2016-03-16  Tom de Vries  <tom@codesourcery.com>

	PR tree-optimization/68715
	* graphite-scop-detection.c (scop_detection::merge_sese): Add missing
	single_pred_p test.

	* gcc.dg/graphite/pr68715-2.c: New test.
	* gcc.dg/graphite/pr68715.c: New test.
	* gfortran.dg/graphite/pr68715.f90: New test.

From-SVN: r234251
2016-03-16 09:19:23 +00:00
Tom de Vries
be7ce7aefd Fix same_close_phi_node
2016-03-16  Tom de Vries  <tom@codesourcery.com>

	PR tree-optimization/68809
	* graphite-scop-detection.c (same_close_phi_node): Test if result types
	are the same.

	* gcc.dg/graphite/pr68809-2.c: New test.
	* gcc.dg/graphite/pr68809.c: New test.

From-SVN: r234250
2016-03-16 09:19:12 +00:00
Jakub Jelinek
6651c93e42 re PR sanitizer/70147 (testcase from hana testsuite gets miscompiled with -fsanitize=undefined)
PR c++/70147
	* cp-ubsan.c (cp_ubsan_dfs_initialize_vtbl_ptrs): Conditionalize
	BINFO_VIRTUAL_P vtable clearing on current_in_charge_parm.

	* g++.dg/ubsan/pr70147-2.C (C::C): Initialize A base with invalid
	method call to i () as argument.  Adjust expected output.

From-SVN: r234249
2016-03-16 08:02:30 +01:00
Jakub Jelinek
1935f2506e re PR sanitizer/70147 (testcase from hana testsuite gets miscompiled with -fsanitize=undefined)
PR c++/70147
	* cp-ubsan.c (cp_ubsan_maybe_initialize_vtbl_ptrs): Temporarily
	set in_base_initializer.

	* g++.dg/ubsan/pr70147-1.C: New test.
	* g++.dg/ubsan/pr70147-2.C: New test.

From-SVN: r234248
2016-03-16 08:01:36 +01:00
Carlos O'Donell
b2de4950df Cleanup and expand on the 'leaf' function attribute documentation.
Describe the problems that a user might face with indirect functions
and ELF symbol interposition.

gcc/ChangeLog:

2016-03-16  Carlos O'Donell  <carlos@redhat.com>
	    Sandra Loosemore  <sandra@codesourcery.com>

	* doc/extend.texi (Common Function Attributes): Describe ifunc impact
	on leaf attribute. Mention ELF interposition problems.


Co-Authored-By: Sandra Loosemore <sandra@codesourcery.com>

From-SVN: r234247
2016-03-16 05:00:58 +00:00
Martin Sebor
ab1caa6e04 PR c++/58281 - Problem with explicitly instantiated constexpr template
PR c++/58281 - Problem with explicitly instantiated constexpr template
	functions

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

	PR c++/58281
	* g++.dg/cpp1y/constexpr-instantiate.C: Add new test.

From-SVN: r234246
2016-03-15 21:00:02 -06:00
GCC Administrator
960fcebd93 Daily bump.
From-SVN: r234245
2016-03-16 00:16:18 +00:00
John David Anglin
cb5d8ad174 pr68532.c: Add -fno-common option on hppa*-*-hpux*.
* gcc.c-torture/execute/pr68532.c: Add -fno-common option on
	hppa*-*-hpux*.

From-SVN: r234242
2016-03-16 00:11:28 +00:00
John David Anglin
b440dd405d ifcvt-4.c: Add hppa*64*-*-* to skip list.
* gcc.dg/ifcvt-4.c: Add hppa*64*-*-* to skip list.

From-SVN: r234241
2016-03-15 23:49:40 +00:00
John David Anglin
5c2a1bbbc2 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
2016-03-15 23:34:49 +00:00
Richard Henderson
64567cfd1d Fix compiling large files
* line-map.c (new_linemap): Make alloc_size a size_t.

From-SVN: r234239
2016-03-15 16:08:45 -07:00
Alan Modra
6585b2e2dd 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
2016-03-16 08:34:42 +10:30
Marek Polacek
42c729c52e 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
2016-03-15 21:10:11 +00:00
Jason Merrill
d1ccf407da 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
2016-03-15 15:37:37 -04:00
Jason Merrill
d4db81a273 Fix more P0184R0 references.
From-SVN: r234230
2016-03-15 15:37:32 -04:00
Jason Merrill
3f91db69ca 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
2016-03-15 15:21:44 -04:00
Alexander Monakov
82b1c550ee 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
2016-03-15 21:11:14 +03:00
Eric Botcazou
2396a7b193 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
2016-03-15 17:55:39 +00:00
Pat Haugen
4ccbf3a66d ifcvt-4.c: Add -misel for powerpc*.
* gcc.dg/ifcvt-4.c: Add -misel for powerpc*.

From-SVN: r234224
2016-03-15 17:45:13 +00:00
Senthil Kumar Selvaraj
79f15a768e 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
2016-03-15 19:21:49 +03:00
Jakub Jelinek
c39858bdb8 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
2016-03-15 17:11:48 +01:00
Jakub Jelinek
511e5c4889 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
2016-03-15 17:10:59 +01:00
Richard Henderson
8be119c16e Fix pr68714 test for targets not supporting V4SImode.
* gcc.dg/tree-ssa/pr68714.c: Test during reassoc pass.

From-SVN: r234220
2016-03-15 08:43:00 -07:00
Andrey Belevantsev
6598bb55e9 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
2016-03-15 18:42:07 +03:00
Andrey Belevantsev
11a6609c19 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
2016-03-15 18:36:44 +03:00
Andrey Belevantsev
81fa2944ec 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
2016-03-15 18:25:41 +03:00
Andrey Belevantsev
74ea9ab61b 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
2016-03-15 18:13:29 +03:00
Tom de Vries
045d50559b 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
2016-03-15 13:01:51 +00:00
Jason Merrill
2aaeea194b 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
2016-03-15 08:08:31 -04:00
Jason Merrill
08da258141 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
2016-03-15 08:08:25 -04:00
Tom de Vries
5a15be975d 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
2016-03-15 11:51:32 +00:00
Martin Sebor
3ea33585de 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
2016-03-14 21:05:17 -06:00
Jason Merrill
08a1cadc10 * c-cppbuiltin.c (c_cpp_builtins): Bump __cpp_range_based_for.
From-SVN: r234207
2016-03-14 22:57:52 -04:00
Segher Boessenkool
26a8813fa3 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
2016-03-15 01:42:43 +01:00
GCC Administrator
26a7773c2f Daily bump.
From-SVN: r234205
2016-03-15 00:16:14 +00:00
David Edelsohn
1df7b330ac * gcc.dg/torture/pr70083.c: Prune non-standard ABI.
From-SVN: r234202
2016-03-14 19:30:52 -04:00
Jakub Jelinek
79b57d18c6 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
2016-03-14 23:19:32 +01:00
Richard Henderson
51d4212ae9 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
2016-03-14 13:48:15 -07:00
Casey Carter
598a208cc0 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
2016-03-14 15:57:54 -04:00