Commit Graph

149122 Commits

Author SHA1 Message Date
Michael Meissner
082139830a rs6000-c.c (rs6000_cpu_cpp_builtins): Split -mfloat128 into -mfloat128-type that enables the IEEE 128-bit floating...
[gcc]
2016-10-06  Michael Meissner  <meissner@linux.vnet.ibm.com>

	* config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Split
	-mfloat128 into -mfloat128-type that enables the IEEE 128-bit
	floating point type infrastructre, and -mfloat128 that enables the
	keyword.  Define __FLOAT128__ if -mfloat128, and __FLOAT128_TYPE__
	if -mfloat128-type.  Define __ibm128 to be long double by default.
	* config/rs6000/rs6000.c (rs6000_debug_reg_global): Print whether
	the IEEE 128-bit floating point type infrastructure should
	automatically be enabled.
	(rs6000_init_hard_regno_mode_ok): Switch to use -mfloat128-type
	instead of -mfloat128 to enable KFmode.
	(rs6000_option_override_internal): Split the option -mfloat128
	into -mfloat128-type and -mfloat128.  On Linux PowerPC 64-bit
	systems, automatically set -mfloat128-type, but don't enable it on
	other operating systems.  Move setting the long double size and
	IEEE quad support before the IEEE 128-bit floating point changes.
	(rs6000_init_builtins): Do not create a unique type for __ibm128
	if long double is IBM extended double, instead rely on __ibm128
	being defined as 'long double'.  If -mfloat128-type and not
	-mfloat128, create the KFmode type with an undocumented __ieee128
	keyword.
	(rs6000_init_libfuncs): Use -mfloat128-type instead of
	-mfloat128 for tests about the types, but keep tests for
	-mfloat128 to enable the keyword support.
	(rs6000_complex_function_value): Likewise.
	(rs6000_scalar_mode_supported_p): Likewise.
	(rs6000_floatn_mode): Likewise.
	(rs6000_c_mode_for_suffix): Likewise.
	(rs6000_opt_masks): Add -mfloat128-type.
	* config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Add support for
	-mfloat128-type being split from -mfloat128.  Add
	-mfloat128-hardware, which was missing.
	* config/rs6000/rs6000.opt (-mfloat128): Split -mfloat128 into
	-mfloat128 and -mfloat128-type:
	(-mfloat128-type): Likewise.
	* config/rs6000/linux64.h (TARGET_FLOAT128_ENABLE_TYPE): Define so
	that 64-bit Linux systems with enable -mfloat128-type by default
	on VSX systems.
	* config/rs6000/rs6000.h (TARGET_FLOAT128_ENABLE_TYPE): Likewise.
	(FLOAT128_VECTOR_P): Switch IEEE 128-bit floating points to use
	-mfloat128-type instead of -mfloat128.
	(FLOAT128_2REG_P): Likewise.
	(MASK_FLOAT128_TYPE): Likewise.
	(ALTIVEC_ARG_MAX_RETURN): Likewise.
	(RS6000_BTM_FLOAT128): Likewise.
	(TARGET_FLOAT128): Poison old identifiers.
	(OPTION_MASK_FLOAT128): Likewise.
	(MASK_FLOAT128): Likewise.
	* config/rs6000/rs6000.md (FP): Likewise.
	(FLOAT128): Likewise.
	(fix_trunc<mode>di2): Likewise.
	(fixuns_trunc<IEEE128:mode><SDI:mode>2): Likewise.
	(floatdi<mode>2): Likewise.
	(floatuns<SDI:mode><IEEE128:mode>2): Likewise.
	(neg<mode>2, FLOAT128 iterator): Likewise.
	(abs<mode>2, FLOAT128 iterator): Likewise.
	(ieee_128bit_negative_zero): Likewise.
	(ieee_128bit_vsx_neg<mode>2): Likewise.
	(ieee_128bit_vsx_neg<mode>2_internal): Likewise.
	(ieee_128bit_vsx_abs<mode>2): Likewise.
	(ieee_128bit_vsx_abs<mode>2_internal): Likewise.
	(ieee_128bit_vsx_nabs<mode>2): Likewise.
	(ieee_128bit_vsx_nabs<mode>2_internal): Likewise.
	(extendiftf2): Likewise.
	(extendifkf2): Likewise.
	(extendtfkf2): Likewise.
	(trunciftf2): Likewise.
	(truncifkf2): Likewise.
	(trunckftf2): Likewise.
	(trunctfif2): Likewise.
	(extendkftf2): Likewise.
	(trunctfkf2): Likewise.

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

	* gcc.target/powerpc/float128-type-1.c: New test to check that
	PowerPC 64-bit Linux enables -mfloat128-type by default.
	* gcc.target/powerpc/float128-type-2.c: Likewise.
	* gcc.target/powerpc/float128-mix.c: Change error message to
	reflect that __ibm128 is now #define'ed to be long double.

From-SVN: r240872
2016-10-07 18:58:10 +00:00
Steven G. Kargl
bd845c14b7 re PR fortran/77406 (ICE in generic_correspondence, at fortran/interface.c:1123)
2016-10-07  Steven G. Kargl  <kargl@gcc.gnu.org>

	PR fortran/77406
	* interface.c (gfc_compare_interfaces): Fix detection of ambiguous
	interface involving alternate return.
	(check_interface1): Improve error message and loci.

2016-10-07  Steven G. Kargl  <kargl@gcc.gnu.org>

	PR fortran/77406
	* gfortran.dg/pr77406.f90: New test.
	* gfortran.dg/assumed_type_3.f90: Update error messages.
	* gfortran.dg/defined_operators_1.f90: Ditto.
	* gfortran.dg/generic_26.f90: Ditto.
	* gfortran.dg/generic_7.f90: Ditto.
	* gfortran.dg/gomp/udr5.f90: Ditto.
	* gfortran.dg/gomp/udr7.f90: Ditto.
	* gfortran.dg/interface_1.f90: Ditto.
	* gfortran.dg/interface_37.f90: Ditto.
	* gfortran.dg/interface_5.f90: Ditto.
	* gfortran.dg/interface_6.f90: Ditto.
	* gfortran.dg/interface_7.f90
	* gfortran.dg/no_arg_check_3.f90
	* gfortran.dg/operator_5.f90
	* gfortran.dg/proc_ptr_comp_20.f90: Ditto.

From-SVN: r240870
2016-10-07 18:18:03 +00:00
Jonathan Wakely
296002c6a1 Improve implementation-defined docs for libstdc++
* doc/xml/manual/status_cxx1998.xml: Improve documentation of
	implementation-defined properties.
	* doc/xml/manual/status_cxx2011.xml: Likewise.
	* doc/xml/manual/status_cxx2017.xml: Likewise.

From-SVN: r240869
2016-10-07 19:02:53 +01:00
Jonathan Wakely
873c7d5ade Implement std::has_unique_object_representations
* doc/xml/manual/status_cxx2017.xml: Update status.
	* include/std/type_traits (has_unique_object_representations): Define.
	* testsuite/20_util/has_unique_object_representations/value.cc: New.
	* testsuite/20_util/has_unique_object_representations/requirements/
	explicit_instantiation.cc: New.
	* testsuite/20_util/has_unique_object_representations/requirements/
	typedefs.cc: New.

From-SVN: r240868
2016-10-07 19:02:43 +01:00
Bernd Edlinger
c09c4992ac re PR c++/77700 (suspicios code in cp/parser.c)
2016-10-07  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        PR c++/77700
        * c-common.c (c_common_truthvalue_conversion): Warn also for
        suspicious enum values in boolean context.

cp:
2016-10-07  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        PR c++/77700
        * parser.c (cp_parser_base_specifier): Fix a warning.

testsuite:
2016-10-07  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        PR c++/77700
        * c-c++-common/Wint-in-bool-context.c: Update test.

From-SVN: r240867
2016-10-07 17:10:38 +00:00
Kyrylo Tkachov
125f0e39bf [simplify-rtx] Zero-initialise local array in simplify_immed_subreg
* simplify-rtx.c (simplify_immed_subreg): Zero-initialize tmp array
	before merging in bytes to pass down to real_from_target.

From-SVN: r240866
2016-10-07 14:47:55 +00:00
Richard Biener
d7f336f846 tree-ssa-propagate.c (replace_phi_args_in): Remove no longer required hack.
2016-10-07  Richard Biener  <rguenther@suse.de>

	* tree-ssa-propagate.c (replace_phi_args_in): Remove no longer
	required hack.
	(substitute_and_fold_dom_walker::before_dom_children):
	Substitute and fold before pass specific folding to avoid
	feeding that with SSA names that will be later released.
	* tree-ssa-ccp.c (get_value_for_expr): Guard for new SSA names
	introduced by folding and visited by evaluate_stmt called during
	ccp_fold_stmt.
	(likely_value): Likewise.
	(evaluate_stmt): Likewise.
	* tree-vrp.c (simplify_truth_ops_using_ranges): Fold modified stmt.
	(simplify_div_or_mod_using_ranges): Likewise.
	(simplify_min_or_max_using_ranges): Likewise.
	(simplify_abs_using_ranges): Likewise.
	(simplify_conversion_using_ranges): Likewise.
	(simplify_float_conversion_using_ranges): Likewise.
	(simplify_stmt_using_ranges): Likewise.

	* gcc.dg/tree-ssa/vrp01.c: Adjust.
	* gcc.dg/tree-ssa/vrp34.c: Likewise.

From-SVN: r240865
2016-10-07 13:47:40 +00:00
Marek Polacek
a9172bf307 gimplify.c (should_warn_for_implicit_fallthrough): Check for FALLTHROUGH_LABEL_P here...
* gimplify.c (should_warn_for_implicit_fallthrough): Check for
	FALLTHROUGH_LABEL_P here...
	(warn_implicit_fallthrough_r): ...not here.

	* c-c++-common/Wimplicit-fallthrough-22.c: New test.

From-SVN: r240864
2016-10-07 12:44:54 +00:00
Bernd Schmidt
8a14afd065 re PR c++/69733 (-Wignored-qualifiers points to wrong const)
c/
	PR c++/69733
	* c-decl.c (smallest_type_quals_location): New static function.
	(grokdeclarator): Try to find the correct location for an ignored
	qualifier.
cp/
	PR c++/69733
	* decl.c (grokdeclarator): Try to find the correct location for an
	ignored qualifier.
testsuite/
	PR c++/69733
	* c-c++-common/pr69733.c: New test.
	* gcc.dg/pr69733.c: New test.
	* gcc.target/i386/pr69733.c: New test.

From-SVN: r240863
2016-10-07 12:21:55 +00:00
Bernd Schmidt
1edfde32a8 re PR tree-optimization/77880 (out of memory building recent LLVM on ppc64le with -O3)
PR tree-optimization/77880
	* expr.c (by_pieces_ninsns): Use unsigned HOST_WIDE_INT where
	necessary.

From-SVN: r240862
2016-10-07 12:16:55 +00:00
Marek Polacek
d4bd46463c re PR c++/77803 (Bogus implicit-fallthrough warning)
PR c++/77803
	* gimplify.c (last_stmt_in_scope): Add check for FALLTHROUGH ().

	* g++.dg/warn/Wimplicit-fallthrough-1.C: New test.

From-SVN: r240861
2016-10-07 11:45:50 +00:00
Richard Biener
7a18d752e7 bitmap.h: Document constraints on bitmap modification while iterating over it.
2016-10-07  Richard Biener  <rguenther@suse.de>

	* bitmap.h: Document constraints on bitmap modification while
	iterating over it.

From-SVN: r240860
2016-10-07 11:26:15 +00:00
Richard Biener
a30fe4b681 bitmap.c (bitmap_elem_to_freelist): Set indx to -1.
2016-10-07  Richard Biener  <rguenther@suse.de>

	* bitmap.c (bitmap_elem_to_freelist): Set indx to -1.
	* bitmap.h (bmp_iter_set): When advancing to the next element
	check that we didn't remove the current one.
	(bmp_iter_and): Likewise.
	(bmp_iter_and_compl): Likewise.
	* tree-ssa.c (release_defs_bitset): Do not remove worklist bit
	we currently iterate on but keep a one-level queue.
	* sched-deps.c (remove_from_deps): Do not clear current bit
	but keep a one-level queue.

From-SVN: r240859
2016-10-07 10:06:24 +00:00
Jakub Jelinek
a93cdc5c6f re PR tree-optimization/77664 (Missed optimization: signed int >= 0 && < unsigned short)
PR tree-optimization/77664
	* tree-ssa-reassoc.c (update_range_test): Also clear low and high
	for the other ranges.
	(optimize_range_tests_diff): Fix up formatting.
	(optimize_range_tests_var_bound): New function.
	(optimize_range_tests): Use it.

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

From-SVN: r240858
2016-10-07 11:33:47 +02:00
Martin Liska
533144bccd Really set priority to 99 for __gcov_exit
* coverage.c (build_gcov_exit_decl): Fix priority what
	should be really 99.

From-SVN: r240857
2016-10-07 09:24:20 +00:00
Martin Liska
5d341f0895 Fix profiled bootstrap (part 2)
* lambda.c (maybe_add_lambda_conv_op): Set default value.

From-SVN: r240856
2016-10-07 08:34:49 +00:00
Richard Biener
014b59e688 gimple-low.c (lower_gimple_bind): Clear DECL_CHAIN of vars in gimple_bind_vars but not in BLOCK_VARS.
2016-10-07  Richard Biener  <rguenther@suse.de>

	* gimple-low.c (lower_gimple_bind): Clear DECL_CHAIN of
	vars in gimple_bind_vars but not in BLOCK_VARS.

From-SVN: r240855
2016-10-07 07:47:38 +00:00
Richard Biener
4023bc5647 re PR tree-optimization/77879 (mpd gets miscompiled since r235622)
2016-10-07  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/77879
	* tree-ssa-structalias.c (handle_const_call): Properly handle
	NRV return slots.
	(handle_pure_call): Likewise.

From-SVN: r240854
2016-10-07 07:44:47 +00:00
Ian Lance Taylor
729232db0b compiler: stack allocate storage for temp slices.
During the lowering phase, the variable arguments to a varargs call are
    packaged up into a temporary slice object; the storage for this slice
    was being unconditionally allocated on the heap.  Heap allocation is not
    necessary, however, if the varargs call correspond to an "append", since
    the append runtime routine only reads the slice storage (as opposed to
    stashing away the storage pointer). Enhance the lowering code to keep
    the slice storage on the stack for append() calls, to improve
    performance.
    
    Addresses issue golang/go#17304.
    
    Reviewed-on: https://go-review.googlesource.com/30136

From-SVN: r240853
2016-10-07 04:14:35 +00:00
Aaron Sawdey
c9616e9af9 2016-10-06 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
* config/rs6000/rs6000.c (rs6000_elf_asm_out_constructor)
	(rs6000_elf_asm_out_destructor): increase size of buf to avoid
	possible overflow.

From-SVN: r240852
2016-10-06 23:12:00 -05:00
Louis Krupp
4ee822df35 [multiple changes]
2016-10-06  Louis Krupp <louis.krupp@zoho.com>

	* gfortran.dg/pr69955.f90: New test.

2016-10-06  Louis Krupp  <louis.krupp@zoho.com>

	PR fortran/69955
	* trans-array.c (gfc_conv_expr_descriptor): Don't allocate
	components if it's not necessary.

From-SVN: r240851
2016-10-07 02:24:40 +00:00
Louis Krupp
ac193ee73c 2016_10-06 Louis Krupp <louis.krupp@zoho.com>
PR fortran/57910
	* gfortran.dg/pr57910.f90: New test.

2016-10-05  Louis Krupp  <louis.krupp@zoho.com>

	PR fortran/57910
	* trans-expr.c (gfc_add_interface_mapping): Don't try to
	dereference call-by-value scalar argument

From-SVN: r240850
2016-10-07 02:02:13 +00:00
GCC Administrator
fe37b0f086 Daily bump.
From-SVN: r240849
2016-10-07 00:16:14 +00:00
Andrew Pinski
4d9205d525 aarch64-cores.def: Add a comment before each set of cores.
2016-10-06  Andrew Pinski  <apinski@cavium.com>

        * config/aarch64/aarch64-cores.def: Add a comment before each
        set of cores.

From-SVN: r240846
2016-10-06 15:49:58 -07:00
Jason Merrill
b7558a2c1f C++17 copy elision improvements.
* call.c (build_temp, convert_like_real): Don't re-copy
	TARGET_EXPR.  Handle packed fields.
	(build_x_va_arg): Wrap it in a TARGET_EXPR.
	(build_over_call): Add sanity check.
	* cvt.c (early_elide_copy): New.
	(ocp_convert): Use it.
	* except.c (build_throw): Use it.
	* init.c (get_nsdmi): Put back the TARGET_EXPR.
	(expand_default_init): Call early_elide_copy.
	* typeck.c (cp_build_modify_expr): Call early_elide_copy.

From-SVN: r240845
2016-10-06 17:24:40 -04:00
Jonathan Wakely
937ec71aba Make std::scoped_allocator_adaptor's OUTERMOST recursive
* doc/xml/manual/status_cxx2011.xml: Update status.
	* include/std/scoped_allocator (__outer_allocator_t, __outermost_type):
	New helpers for recursive OUTERMOST.
	(__outermost): Use __outermost_type::_S_outermost.
	(__do_outermost, scoped_allocator_adaptor::__outermost_type): Remove.
	(scoped_allocator_adaptor::__outermost_alloc_traits): Use new
	__outermost_type helper.
	* testsuite/20_util/scoped_allocator/outermost.cc: New test.

From-SVN: r240844
2016-10-06 22:22:35 +01:00
Jakub Jelinek
342cfb3e73 Implement P0258R2 - helper for C++17 std::has_unique_object_representations trait c-family/
Implement P0258R2 - helper for C++17
	std::has_unique_object_representations trait
c-family/
	* c-common.h (enum rid): Add RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
	* c-common.c (c_common_reswords): Add
	__has_unique_object_representations.
cp/
	* cp-tree.h (enum cp_trait_kind): Add
	CPTK_HAS_UNIQUE_OBJ_REPRESENTATIONS.
	(struct lang_type_class): Add unique_obj_representations
	and unique_obj_representations_set bitfields.
	(CLASSTYPE_UNIQUE_OBJ_REPRESENTATIONS,
	CLASSTYPE_UNIQUE_OBJ_REPRESENTATIONS_SET): Define.
	(type_has_unique_obj_representations): Declare.
	* parser.c (cp_parser_primary_expression): Handle
	RID_HAS_UNIQUE_OBJ_REPRESENTATIONS.
	(cp_parser_trait_expr): Likewise.  Formatting fix.
	* semantics.c (trait_expr_value, finish_trait_expr): Handle
	CPTK_HAS_UNIQUE_OBJ_REPRESENTATIONS.
	* tree.c (type_has_unique_obj_representations): New function.
	(record_has_unique_obj_representations): New function.
	* cxx-pretty-print.c (pp_cxx_trait_expression): Handle
	CPTK_HAS_UNIQUE_OBJ_REPRESENTATIONS.
testsuite/
	* g++.dg/cpp1z/has-unique-obj-representations1.C: New test.
	* g++.dg/cpp1z/has-unique-obj-representations2.C: New test.

From-SVN: r240843
2016-10-06 23:17:44 +02:00
Kugan Vivekanandarajah
480570898d re PR tree-optimization/77862 (ice in add_equivalence)
Fix PR77862
gcc/testsuite/ChangeLog:

2016-10-06  Kugan Vivekanandarajah  <kuganv@linaro.org>

	PR tree-optimization/77862
	* gcc.dg/pr77862.c: New test.

gcc/ChangeLog:

2016-10-06  Kugan Vivekanandarajah  <kuganv@linaro.org>

	PR tree-optimization/77862
	* tree-vrp.c (add_equivalence): Use get_value_range so that
	num_vr_values is checked before accessing vr_values.

From-SVN: r240842
2016-10-06 19:58:46 +00:00
Kugan Vivekanandarajah
65b25c9b43 Handle POINTER_TYPE_P in EVRP
Handle POINTER_TYPE_P in EVRP
gcc/ChangeLog:

2016-10-06  Kugan Vivekanandarajah  <kuganv@linaro.org>

	* tree-vrp.c (evrp_dom_walker::before_dom_children): Handle
	  POINTER_TYPE_P.


gcc/testsuite/ChangeLog:

2016-10-06  Kugan Vivekanandarajah  <kuganv@linaro.org>

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

From-SVN: r240841
2016-10-06 19:55:14 +00:00
Chris Manghane
4c4430e390 go-gcc.cc (Gcc_backend::stack_allocation_expression): Clear the returned memory.
* go-gcc.cc (Gcc_backend::stack_allocation_expression): Clear the
	returned memory.

From-SVN: r240840
2016-10-06 19:24:04 +00:00
Jeff Law
f31276858a re PR tree-optimization/71661 (wrong code at -O3)
PR tree-optimization/71661
	* tree-cfgcleanup.c (remove_forwarder_block_with_phi): Handle case when
	removal of a forwarder exposes a new natural loop.

	PR tree-optimization/71661
	* gcc.dg/tree-ssa/pr71661.c: New test.

From-SVN: r240836
2016-10-06 10:23:22 -06:00
Uros Bizjak
63656b8da2 * config/i386/i386.c (ix86_add_stmt_cost): Simplify condition.
From-SVN: r240835
2016-10-06 16:57:41 +02:00
Uros Bizjak
271319ae2b sse.md (andnot<mode>3): Add FALLTHRU comments.
* config/i386/sse.md (andnot<mode>3): Add FALLTHRU comments.
	Introduce ssesuffix variable.
	(<mask_codefor><code><mode>3<mask_name>): Ditto.
	(*<code><mode>3): Ditto.

From-SVN: r240834
2016-10-06 16:56:34 +02:00
Jan Hubicka
c6a2617973 postreload.c (reload_cse_simplify): Skip also USE when detecting noop move.
* postreload.c (reload_cse_simplify): Skip also USE when detecting
	noop move.

From-SVN: r240833
2016-10-06 13:45:45 +00:00
Richard Biener
b397258804 re PR tree-optimization/77855 (wrong code at -O3 on x86_64-linux-gnu (in both 32-bit and 64-bit modes))
2016-10-06  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/77855
	* tree-ssa-pre.c (prune_clobbered_mems): Queue exprs to remove
	instead of removing the current item while iterating over the set
	which is not safe.

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

From-SVN: r240832
2016-10-06 12:17:53 +00:00
James Clarke
139dc3c651 re PR target/77759 (ICE in function_arg_record_value on nested empty class)
PR target/77759
	* config/sparc/sparc.c (classify_data_t): Remove int_regs field.
	(classify_registers): Don't set it
	(function_arg_slotno): Don't initialize and test it.  Tidy up.

Co-Authored-By: Eric Botcazou <ebotcazou@adacore.com>

From-SVN: r240830
2016-10-06 10:28:23 +00:00
Richard Biener
37f6a157f5 re PR tree-optimization/77839 (Memory- and compile time hog at -O1 and above)
2016-10-06  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/77839
	* tree-ssa-sccvn.c (set_ssa_val_to): Forbid value -> constant value
	lattice transition.

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

From-SVN: r240829
2016-10-06 08:54:37 +00:00
Martin Liska
2d5edbede6 Add -fprofile-update option juggling
* gcc.c: Set -fprofile-update=atomic when profiling is
	enabled and -pthread is set.  Warn when one combines
	-pthread and -fprofile-update=single for an app using
	profiling code.

From-SVN: r240828
2016-10-06 07:34:23 +00:00
Martin Liska
ac2a97db4b Fix warnings for make profiledbootstrap (PR bootstrap/77788)
PR bootstrap/77788
	* expmed.h (mul_highpart_cost_ptr): Add an gcc_assert.
	* gimple-ssa-strength-reduction.c (slsr_process_cast):
	Initialize a pointer to NULL.
	(slsr_process_copy): Likewise.
	* input.c (location_get_source_line): Likewise.
	* tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.

From-SVN: r240827
2016-10-06 07:33:49 +00:00
Ian Lance Taylor
a7773b4d06 escape: Avoid allocation of varargs parameter.
There was a bug in the escape analysis that would cause
    the slice implicitly created to hold varargs parameters to always
    escape, as well as the appended to slice argument.  The intended
    behavior was that the elements of the appendee and appended to
    slice would escape to the heap.  Alongside of these issues,
    the varargs slice would also have a chance to be initialized to an
    invalid memory location if it were stack-allocated.  This has been
    fixed as well.
    
    Reviewed-on: https://go-review.googlesource.com/30450

From-SVN: r240826
2016-10-06 03:51:03 +00:00
Marek Polacek
f779aeb8af * g++.dg/cpp1z/init-statement9.C: New test.
From-SVN: r240824
2016-10-06 00:25:29 +00:00
GCC Administrator
9519da989c Daily bump.
From-SVN: r240823
2016-10-06 00:16:17 +00:00
Jason Merrill
bf9b09fbe2 Implement P0135R1, Guaranteed copy elision.
* cvt.c (ocp_convert): Don't re-copy a TARGET_EXPR in C++17.

From-SVN: r240820
2016-10-05 18:59:02 -04:00
Jason Merrill
5794b9f622 PR c++/54293 - binding reference to member of temporary
* call.c (reference_binding): Fix binding to member of temporary.

From-SVN: r240819
2016-10-05 18:58:55 -04:00
Jason Merrill
27afd940ce * call.c (extend_ref_init_temps): Fix TARGET_EXPR handling.
From-SVN: r240818
2016-10-05 18:57:58 -04:00
Andrew Senkevich
eee8f0b07f Delete x86 deprecated pcommit instruction support
Delete x86 pcommit instruction support, which has been deprecated:

https://software.intel.com/en-us/blogs/2016/09/12/deprecate-pcommit-instruction

gcc/

	* common/config/i386/i386-common.c (OPTION_MASK_ISA_PCOMMIT_UNSET,
	OPTION_MASK_ISA_PCOMMIT_SET): Deleted definitions.
	(ix86_handle_option): Deleted handle of OPT_mpcommit.
	* config.gcc: Deleted pcommitintrin.h
	* config/i386/pcommitintrin.h: Deleted file.
	* config/i386/cpuid.h (bit_PCOMMIT): Deleted.
	* config/i386/driver-i386.c (host_detect_local_cpu): Deleted pcommit
	detection.
	* config/i386/i386-c.c (ix86_target_macros_internal): Deleted define
	__PCOMMIT__.
	* config/i386/i386.c (ix86_target_string): Deleted -mpcommit.
	(PTA_PCOMMIT): Deleted define.
	(ix86_option_override_internal): Deleted handle of option.
	(ix86_valid_target_attribute_inner_p): Deleted pcommit.
	* config/i386/i386-builtin.def (IX86_BUILTIN_PCOMMIT,
	__builtin_ia32_pcommit): Deleted.
	* config/i386/i386.h (TARGET_PCOMMIT, TARGET_PCOMMIT_P): Deleted.
	* config/i386/i386.md (unspecv): Deleted UNSPECV_PCOMMIT.
	(pcommit): Deleted instruction.
	* config/i386/i386.opt: Mention -mpcommit deprecation.
	* config/i386/x86intrin.h: Deleted inclusion of pcommitintrin.h.

gcc/testsuite/

	* gcc.target/i386/pcommit-1.c: Deleted.
	* gcc.target/i386/sse-12.c: Deleted -pcommit option.
	* gcc.target/i386/sse-13.c: Ditto.
	* gcc.target/i386/sse-14.c: Ditto.
	* gcc.target/i386/sse-22.c: Ditto.
	* gcc.target/i386/sse-23.c: Ditto.
	* g++.dg/other/i386-2.C: Ditto.

From-SVN: r240816
2016-10-05 15:08:48 -07:00
Uros Bizjak
b48042bb40 pr77833.c: Require int128 effective target.
* gcc.target/i386/pr77833.c: Require int128 effective target.

From-SVN: r240815
2016-10-06 00:06:37 +02:00
Uros Bizjak
c617339332 re PR target/77874 (two problems with gcc.target/i386/avx-1.c)
PR target/77874
	* config/i386/sse.md (<mask_codefor><code><mode>3<mask_name>):
	Remove wrong assert.
	(<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>:
	Use <round_constraint> as operand 1 constraint.

From-SVN: r240814
2016-10-06 00:02:05 +02:00
Steven G. Kargl
50b01e1d46 re PR fortran/58991 (ICE with associate and character string constant)
2016-10-05  Steven G. Kargl  <kargls@gcc.gnu.org>

	PR fortran/58991
	PR fortran/58992
	* resolve.c (resolve_assoc_var):  Fix CHARACTER type-spec for a
	selector in ASSOCIATE.
	(resolve_fl_variable): Skip checks for an ASSOCIATE variable.


2016-10-05  Steven G. Kargl  <kargls@gcc.gnu.org>

	PR fortran/58991
	PR fortran/58992
	* gfortran.dg/associate_22.f90: New test.

From-SVN: r240812
2016-10-05 21:14:14 +00:00
Fritz Reese
908b82964e Fix ICE due to comparison between UNION components.
2016-10-05  Fritz Reese  <fritzoreese@gmail.com>

Fix ICE due to comparison between UNION components.

	gcc/fortran/
	* interface.c (gfc_compare_types): Don't compare BT_UNION components
	until we know they're both UNIONs.
	* interface.c (gfc_compare_union_types): Guard against empty
	components.

	gcc/testsuite/gfortran.dg/
	* dec_union_9.f90: New testcase.
	* dec_union_10.f90: New testcase.

From-SVN: r240810
2016-10-05 20:24:48 +00:00