Commit Graph

144658 Commits

Author SHA1 Message Date
Jakub Jelinek
411d61c4af decl.c (start_preparsed_function): Don't emit start clobber at the start of constructor clones.
* decl.c (start_preparsed_function): Don't emit start clobber at the
	start of constructor clones.

From-SVN: r233985
2016-03-04 23:11:41 +01:00
Jakub Jelinek
0c8825de94 re PR c++/70035 (Calling a non-virtual member in base-class constructor call with ubsan causes segfault when superclass has virtual member with same name)
PR c++/70035
	* cp-tree.h (cp_ubsan_maybe_initialize_vtbl_ptrs): New prototype.
	* decl.c (start_preparsed_function): Call
	cp_ubsan_maybe_initialize_vtbl_ptrs if needed.
	* cp-ubsan.c (cp_ubsan_dfs_initialize_vtbl_ptrs,
	cp_ubsan_maybe_initialize_vtbl_ptrs): New functions.

	* g++.dg/ubsan/pr70035.C: New test.

From-SVN: r233984
2016-03-04 23:10:49 +01:00
Jason Merrill
188e53bd7e re PR c++/67364 ("accessing uninitialized member" error in constexpr context)
PR c++/67364

	* constexpr.c (cxx_eval_component_reference): Further tweak.

From-SVN: r233982
2016-03-04 17:08:22 -05:00
Jason Merrill
39dce2b790 Fix constexpr handling of SAVE_EXPR in loops.
* constexpr.c (struct constexpr_ctx): Add save_exprs field.
	(cxx_eval_loop_expr): Discard SAVE_EXPR values before looping.
	(cxx_eval_constant_expression) [SAVE_EXPR]: Add it to the set.
	(cxx_eval_outermost_constant_expr, is_sub_constant_expr): Initialize.

From-SVN: r233981
2016-03-04 17:08:17 -05:00
Jakub Jelinek
6020455464 re PR target/70062 (ICE: in decide_alg, at config/i386/i386.c:26173 with -mmemcpy-strategy=libcall)
PR target/70062
	* config/i386/i386.c (decide_alg): Add RECUR argument.  Revert
	2016-02-22 changes, instead don't recurse if RECUR is already true.
	Don't change *dynamic_check if RECUR.  Adjust recursive caller
	to pass true to the new argument.
	(ix86_expand_set_or_movmem): Adjust decide_alg caller.

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

From-SVN: r233979
2016-03-04 21:28:27 +01:00
H.J. Lu
f79d4eabaf Remove c++98_only on g++.dg/template/typename21.C
* g++.dg/template/typename21.C: Remove c++98_only.

From-SVN: r233977
2016-03-04 11:51:53 -08:00
H.J. Lu
ea81ce67b9 Replace c++98 with c++98_only
* g++.dg/template/typename21.C: Replace c++98 with c++98_only.

From-SVN: r233975
2016-03-04 11:41:35 -08:00
Jason Merrill
b54eff8bb1 re PR c++/70067 (internal compiler error: in strip_typedefs, at cp/tree.c:1466)
PR c++/70067

	* tree.c (strip_typedefs): Handle TYPENAME_TYPE lookup finding the
	same type.

From-SVN: r233973
2016-03-04 11:07:20 -05:00
David Malcolm
64b23c13dc PR c/68187: fix overzealous -Wmisleading-indentation (comment #1)
gcc/c-family/ChangeLog:
	PR c/68187
	* c-indentation.c (get_visual_column): Move code to determine next
	tab stop to...
	(next_tab_stop): ...this new function.
	(line_contains_hash_if): Delete function.
	(detect_preprocessor_logic): Delete function.
	(get_first_nws_vis_column): New function.
	(detect_intervening_unindent): New function.
	(should_warn_for_misleading_indentation): Replace call to
	detect_preprocessor_logic with a call to
	detect_intervening_unindent.

gcc/testsuite/ChangeLog:
	PR c/68187
	* c-c++-common/Wmisleading-indentation.c (fn_42_a): New test
	function.
	(fn_42_b): Likewise.
	(fn_42_c): Likewise.

From-SVN: r233972
2016-03-04 15:50:27 +00:00
David Malcolm
729526f5d4 PR c/68187: fix overzealous -Wmisleading-indentation (comment #0)
gcc/c-family/ChangeLog:
	PR c/68187
	* c-indentation.c (should_warn_for_misleading_indentation): When
	suppressing warnings about cases where the guard and body are on
	the same column, only use the first non-whitespace column in place
	of the guard token column when dealing with "else" clauses.
	When rejecting aligned BODY and NEXT, loosen the requirement
	from equality with the first non-whitespace of guard to simply
	that they not be indented relative to it.

gcc/testsuite/ChangeLog:
	PR c/68187
	* c-c++-common/Wmisleading-indentation.c (fn_40_a): New test
	function.
	(fn_40_b): Likewise.
	(fn_41_a): Likewise.
	(fn_41_b): Likewise.

From-SVN: r233971
2016-03-04 15:45:19 +00:00
Jakub Jelinek
f9ea11ac19 re PR target/70059 (Invalid codegen on AVX-512 when using _mm512_inserti64x4(x, y, 0))
PR target/70059
	* config/i386/sse.md (vec_set_lo_<mode><mask_name>,
	<extract_type_2>_vinsert<shuffletype><extract_suf_2>_mask): Formatting
	fixes.
	(vec_set_hi_<mode><mask_name>): Likewise.  Swap VEC_CONCAT operands.

	* gcc.target/i386/avx512f-pr70059.c: New test.
	* gcc.target/i386/avx512dq-pr70059.c: New test.

From-SVN: r233968
2016-03-04 15:45:56 +01:00
Bernd Schmidt
b6c38c6958 Avoid terminating early in LRA, unless -fchecking (PR57676)
gcc/
	PR rtl-optimization/57676
	* lra-assigns.c (lra_assign): Guard test for maximum iterations
	with flag_checking.

gcc/testsuite/
	PR rtl-optimization/57676
	* gcc.dg/torture/pr57676.c: New test.

From-SVN: r233967
2016-03-04 14:12:36 +00:00
Ilya Enkovich
af3cdd3433 tree-vect-patterns.c (search_type_for_mask): Handle comparison of booleans.
gcc/

	* tree-vect-patterns.c (search_type_for_mask): Handle
	comparison of booleans.

gcc/testsuite/

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

From-SVN: r233966
2016-03-04 13:49:54 +00:00
Marek Polacek
7ff6ca3899 re PR c/69798 (ICE on invalid code on x86_64-linux-gnu in c_parser_braced_init, at c/c-parser.c:4338)
PR c/69798
	* c-parser.c (c_parser_postfix_expression): Call
	c_parser_cast_expression rather than c_parser_postfix_expression.

	* gcc.dg/cilk-plus/pr69798-1.c: New test.
	* gcc.dg/cilk-plus/pr69798-2.c: New test.

From-SVN: r233965
2016-03-04 13:26:25 +00:00
Kyrylo Tkachov
a6bf62d5f8 [AArch64][testsuite] PR target/70004: Remove check using undefined behaviour
PR target/70004
	* gcc.target/aarch64/scalar_shift_1.c: (test_corners_sisd_di):
	Delete.
	(test_corners_sisd_si): Likewise.
	(main): Remove checks of the above.
	* gcc.target/aarch64/shift_wide_invalid_1.c: New test.

From-SVN: r233964
2016-03-04 11:09:11 +00:00
Eric Botcazou
ae4cdc6a98 * gcc.dg/Wno-frame-address.c: Skip on IA-64.
From-SVN: r233963
2016-03-04 08:46:33 +00:00
Christophe Lyon
08455559f4 pr69951.c: Accept argc==0.
2016-03-04  Christophe Lyon  <christophe.lyon@linaro.org>

	* gcc.dg/torture/pr69951.c: Accept argc==0.

From-SVN: r233962
2016-03-04 09:43:27 +01:00
Richard Biener
e9a35493b0 re PR middle-end/70054 (GCC 6 gives a strict-aliasing warning on use of std::aligned_storage)
2016-03-04  Richard Biener  <rguenther@suse.de>

	PR c++/70054
	* c-common.c (strict_aliasing_warning): Use alias_set_subset_of
	instead of alias_sets_conflict_p.

	* g++.dg/warn/Wstrict-aliasing-bogus-union-2.C: New testcase.
	* gcc.dg/Wstrict-aliasing-struct-member.c: New testcase.

From-SVN: r233961
2016-03-04 08:31:19 +00:00
Jakub Jelinek
6a27431a54 extend.texi (__builtin_alloca, [...]): Fix @xref usage.
* doc/extend.texi (__builtin_alloca, __builtin_alloca_with_align):
	Fix @xref usage.

From-SVN: r233960
2016-03-04 08:39:21 +01:00
Dominik Vogt
fba054c268 S/390: Set GOARCH to the current target when testing multiarch.
The attached patch fixes a test failure of go.test/test/env.go on
s390x biarch.  Bootstrapped and regression tested on s390x biarch
and s390.

gcc/testsuite/ChangeLog

2016-03-04  Dominik Vogt  <vogt@linux.vnet.ibm.com>

	PR testsuite/69766
	* go.test/go-test.exp: S/390: Set GOARCH to the current target when
	testing multiarch.

From-SVN: r233959
2016-03-04 07:33:16 +00:00
Jakub Jelinek
f10cdc6c14 re PR debug/69947 (DW_OP_GNU_implicit_pointer broken on the trunk)
PR debug/69947
	* dwarf2out.c (prune_unused_types_walk_loc_descr): Handle
	all other ops that have dw_val_class_die_ref operands,
	and DW_OP_GNU_entry_value.

	* gcc.dg/guality/pr69947.c: New test.

From-SVN: r233958
2016-03-04 08:27:15 +01:00
Jason Merrill
b47d1d904d * method.c (synthesized_method_walk): operator= can also be constexpr.
From-SVN: r233956
2016-03-03 20:48:33 -05:00
Jason Merrill
a0a6a8c966 pt.c (tsubst_copy_and_build): Get LAMBDA_EXPR_RETURN_TYPE from the instantiated closure.
* pt.c (tsubst_copy_and_build) [LAMBDA_EXPR]: Get
	LAMBDA_EXPR_RETURN_TYPE from the instantiated closure.

From-SVN: r233955
2016-03-03 20:45:48 -05:00
Jason Merrill
264fd1424e re PR c++/67164 (ICE: tree check: expected class ‘expression’, have ‘exceptional’ (argument_pack_select) in tree_operand_check, at tree.h:3356)
PR c++/67164

	* pt.c (copy_template_args): New.
	(tsubst_pack_expansion): Use it.

From-SVN: r233954
2016-03-03 20:45:43 -05:00
GCC Administrator
6fdb0d67d0 Daily bump.
From-SVN: r233953
2016-03-04 00:16:16 +00:00
Jason Merrill
45c3e69bb7 * call.c (build_aggr_conv): Use get_nsdmi.
From-SVN: r233947
2016-03-03 17:43:14 -05:00
Jason Merrill
16dc6b178a re PR c++/51406 ([c++0x] Incorrect result of static_cast to rvalue reference to base class.)
PR c++/51406

	* typeck.c (build_static_cast_1): Avoid folding back to lvalue.

From-SVN: r233946
2016-03-03 17:43:09 -05:00
Jason Merrill
639475f047 re PR c++/67364 ("accessing uninitialized member" error in constexpr context)
PR c++/67364

	* constexpr.c (cxx_eval_component_reference): Just return an empty
	CONSTRUCTOR for an empty class.

From-SVN: r233945
2016-03-03 17:43:03 -05:00
Jakub Jelinek
2e981ba068 re PR ada/70017 (c52103x and c52104x test failure on s390x)
PR ada/70017
	* gcc.dg/pr70017.c (foo): Store 0 to first element of each array.

From-SVN: r233944
2016-03-03 21:52:40 +01:00
Kyrylo Tkachov
0ba3bfa2b0 [ARM] PR rtl-optimization/69904: Disallow copying/duplicating of load-exclusive operations
PR rtl-optimization/69904
	* config/arm/arm.c (arm_cannot_copy_insn_p):
	Return true for load-exclusive instructions.

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

From-SVN: r233941
2016-03-03 17:25:43 +00:00
Jakub Jelinek
97ecdb46b1 re PR target/70021 (Test miscompiled with -O3 option for -march=core-avx2.)
PR target/70021
	* tree-vect-stmts.c (vect_mark_relevant): Remove USED_IN_PATTERN
	argument, if STMT_VINFO_IN_PATTERN_P (stmt_info), always mark
	the pattern no matter if it is used just by non-pattern, pattern
	or mix thereof.
	(process_use, vect_mark_stmts_to_be_vectorized): Adjust callers.
	* tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern): If
	oprnd1 def_stmt is in pattern, don't look through it.

	* gcc.dg/vect/pr70021.c: New test.
	* gcc.target/i386/pr70021.c: New test.

From-SVN: r233940
2016-03-03 15:32:15 +01:00
Rainer Orth
bc33dc51d9 Fix passing object names to make_sunver.pl
* Makefile.am (libffi.map-sun): Properly convert
	$(libffi_la_OBJECTS) to object names.
	* Makefile.in: Regenerate.

From-SVN: r233938
2016-03-03 13:40:30 +00:00
Marek Polacek
a2a743a13a re PR middle-end/70050 (ICE: tree check: expected integer_type or enumeral_type or boolean_type or real_type or fixed_point_type, have vector_type in generic_simplify_162, at generic-match.c:6175)
PR middle-end/70050
	* match.pd (X % -Y): Add INTEGRAL_TYPE_P check.

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

From-SVN: r233937
2016-03-03 11:42:19 +00:00
Rainer Orth
fd2298e3e1 Tabify libffi/Makefile.am
* Makefile.am (libffi.map-sun): Tabify:
	* Makefile.in: Regenerate.

From-SVN: r233936
2016-03-03 10:30:25 +00:00
James Greenhalgh
fa07ecdd21 [Patch testsuite] Change xfail conditions for bb-slp-34.c
gcc/testsuite/

	* gcc.dg/vect/bb-slp-34.c: Don't XFAIL for ARM/AArch64.

From-SVN: r233935
2016-03-03 10:18:05 +00:00
Martin Liska
2350426232 Skip properly debug stmt in optimize_mask_stores (PR
PR tree-optimization/70043
	* tree-vect-loop.c (optimize_mask_stores): Move iterator to
	previous statement if we see a debug statement.
	* gfortran.dg/vect/pr70043.f90: New test.

From-SVN: r233934
2016-03-03 10:08:09 +00:00
Eric Botcazou
b7b9e1a958 * gnat.dg/specs/task1.ads: New test.
From-SVN: r233932
2016-03-03 09:56:30 +00:00
Rainer Orth
cb83ba54b5 Invoke gdb with -batch to avoid prompts
* lib/gcc-gdb-test.exp (gdb-test): Make log message match command.
	Invoke gdb with -batch.
	* lib/gcc-simulate-thread.exp (simulate-thread): Likewise.

From-SVN: r233930
2016-03-03 09:46:03 +00:00
Dominik Vogt
edcbda7e2c libitm: Introduce target macro TARGET_BEGIN_TRANSACTION_ATTRIBUTE.
The attached patch adds the a target specific attribute via the
new target macro TARGET_BEGIN_TRANSACTION_ATTRIBUTE to the
function begin_transaction().  S/390 uses this to set the
soft-float target attribute which is needed to fix a crash with
-m31.

As there seems to be no place in libitm to document internal macros like
USE_HTM_FASTPATH or the new macro, I've put the documentation in a
comment where the macro is used.

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

	* config/s390/target.h (TARGET_BEGIN_TRANSACTION_ATTRIBUTE): Define
	function attribute to disable floating point in begin_transaction() on
	S/390.
	* beginend.cc (begin_transaction): Use
	TARGET_BEGIN_TRANSACTION_ATTRIBUTE.

From-SVN: r233929
2016-03-03 09:31:57 +00:00
Richard Biener
a75f5e30cc re PR tree-optimization/55936 (Missed VRP optimization)
2016-03-03  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/55936
	* tree-vrp.c (compare_name_with_value): Add use_equiv_p
	parameter and guard unsafe equivalence use.
	(vrp_evaluate_conditional_warnv_with_ops): Always use
	safe equivalences but not via the quadratic compare_names
	helper.

	* gcc.dg/tree-ssa/vrp06.c: Remove XFAIL.

From-SVN: r233928
2016-03-03 09:12:53 +00:00
Michael Collison
0a67ef4c4d re PR target/70014 ([ARM] Predicate does not match constraint (*subsi3_carryin_const))
2016-03-03  Michael Collison  <michael.collison@linaro.org>

	PR target/70014
	* config/arm/arm.md (*subsi3_carryin_const): Change predicate
	for operand 1 to s_register_operand. Change predicate for operand
	2 to arm_not_immediate_operand.

From-SVN: r233927
2016-03-03 07:42:02 +00:00
Richard Henderson
5147e0e84e re PR libffi/70024 (libffi ABI change w/o SONAME bump)
PR libffi/70024

  * Makefile.am (libffi_version_script): Look in cwd for libffi.map.
  (libffi_version_dep, libffi.map-sun): Likewise.
  (libffi.map): New target.
  * libffi.map.in: Rename from libffi.map.  Add required defines,
  includes, and conditionals.

From-SVN: r233926
2016-03-02 17:40:29 -08:00
GCC Administrator
72c5cfd205 Daily bump.
From-SVN: r233925
2016-03-03 00:16:13 +00:00
Jeff Law
815f20ab25 re PR rtl-optimization/69942 (gcc.dg/ifcvt-5.c FAILs)
PR rtl-optimization/69942
	* gcc.dg/ifcvt-5.c: Use "word_mode" rather than "int" to limit the
	effects of argument promotions.

From-SVN: r233922
2016-03-02 17:11:03 -07:00
Richard Henderson
2c05525623 re PR libffi/70024 (libffi ABI change w/o SONAME bump)
PR libffi/70024

  * Makefile.am (libffi_version_script): New.
  (libffi_version_dep): New.
  (libffi_version_info): New.
  (libffi_la_LDFLAGS): Include libffi_version_info, libffi_version_script.
  (libffi_la_DEPENDENCIES): Include libffi_version_dep.
  * acinclude.m4 (LIBAT_ENABLE, LIBAT_CHECK_LINKER_FEATURES): New.
  (LIBAT_ENABLE_SYMVERS, LIBAT_BUILD_VERSIONED_SHLIB): New.
  (LIBAT_BUILD_VERSIONED_SHLIB_GNU): New.
  (LIBAT_BUILD_VERSIONED_SHLIB_SUN): New.
  * configure.ac: Invoke LIBAT_ENABLE_SYMVERS.
  * libffi.map: New file.
  * libtool-version: Increase to 5.0.0.
  * Makefile.in, configure: Rebuild.
  * man/Makefile.in, testsuite/Makefile.in: Rebuild.

From-SVN: r233921
2016-03-02 15:28:11 -08:00
Jeff Law
9d83ef7171 Fix recent ChangeLog entry
From-SVN: r233918
2016-03-02 14:56:25 -07:00
H.J. Lu
52dcb7dbeb Regenerate doc/tm.texi
* doc/tm.texi: Regenerated.

From-SVN: r233917
2016-03-02 13:46:55 -08:00
Richard Henderson
08c1904dcc re PR rtl-optimization/67145 (associativity from pseudo-reg ordering)
PR rtl-opt/67145

  * simplify-rtx.c (simplify_plus_minus): Allow reassoc without
  simplification when all args are positive non-fixed registers.

From-SVN: r233916
2016-03-02 13:09:54 -08:00
Jakub Jelinek
82ee0cf2f7 Minor ChangeLog formatting fixes.
From-SVN: r233915
2016-03-02 21:30:48 +01:00
Manuel López-Ibáñez
bdfbd08637 target.def (lra_p): Specify that new ports should use LRA.
2016-03-02  Manuel Lopez-Ibanez <manu@gcc.gnu.org>

       * target.def(lra_p): Specify that new ports should use LRA.

From-SVN: r233914
2016-03-02 20:17:15 +00:00