Commit Graph

135673 Commits

Author SHA1 Message Date
H.J. Lu
ff8ebda16a Set TARGET to X86_64 if __x86_64__ is defined
PR bootstrap/64575
	* configure.host (TARGET): Set to X86_64 if __x86_64__ is defined.

From-SVN: r219539
2015-01-13 07:57:27 -08:00
Richard Henderson
be723d1e73 re PR libffi/64572 (r219477 breaks bootstrap on x86_64 darwin)
PR libffi/64572

 * src/x86/ffitarget.h (FFI_GO_CLOSURES): Do not define for darwin.
 (FFI_TARGET_HAS_COMPLEX_TYPE): Likewise.

From-SVN: r219538
2015-01-13 07:29:47 -08:00
Jonathan Wakely
6eb6148159 re PR libstdc++/64571 (Link failure with fstream due to new string implementation)
PR libstdc++/64571
	* config/abi/pre/gnu.ver: Export fstream functions using new string.

From-SVN: r219537
2015-01-13 14:56:50 +00:00
Richard Sandiford
7eb8fb77fa gcc/
* config/aarch64/aarch64.md (subsi3, *subsi3_uxtw, subdi3)
	(*sub_<optab><ALLX:mode>_<GPI:mode>, *sub_<optab><SHORT:mode>_si_uxtw)
	(*sub_<optab><ALLX:mode>_shft_<GPI:mode>)
	(*sub_<optab><SHORT:mode>_shft_si_uxtw, *sub_<optab><mode>_multp2)
	(*sub_<optab>si_multp2_uxtw, *sub_uxt<mode>_multp2)
	(*sub_uxtsi_multp2_uxtw): Add stack pointer sources.

gcc/testsuite/
	* gcc.target/aarch64/subsp.c: New test.

From-SVN: r219533
2015-01-13 14:11:15 +00:00
Andrew Pinski
1f46bd52c5 2015-01-13 Andrew Pinski <apinski@cavium.com>
* config/aarch64/aarch64.c (fusion_load_store): Check dest mode
        instead of src mode.


2015-01-13  Andrew Pinski  <apinski@cavium.com>

        * gcc.target/aarch64/store-pair-1.c: New testcase.

From-SVN: r219532
2015-01-13 06:08:21 -08:00
Richard Biener
e0ffb247d6 re PR lto/64373 (ICE with lto related to variably modified type)
2015-01-13  Richard Biener  <rguenther@suse.de>

	PR lto/64373
	* lto-streamer-out.c (tree_is_indexable): Guard for NULL
	DECL_CONTEXT.

	* gcc.dg/lto/pr64373_0.c: New testcase.

From-SVN: r219531
2015-01-13 13:57:27 +00:00
Andrew Pinski
bf84ac44f9 [multiple changes]
2015-01-13  Andrew Pinski   <apinski@cavium.com>

        * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp): Reject
        volatile mems.
        (aarch64_operands_adjust_ok_for_ldpstp): Likewise.


2015-01-13  Andrew Pinski  <apinski@cavium.com>

        * gcc.target/aarch64/volatileloadpair-1.c: New testcase.
        * gcc.target/aarch64/volatileloadpair-2.c: New testcase.

From-SVN: r219530
2015-01-13 05:55:23 -08:00
Jakub Jelinek
08cb0abc7c re PR middle-end/63974 (gcc.c-torture/compile/991213-3.c ICEs with -mabi=ilp32)
PR middle-end/63974
	* cfgexpand.c (expand_computed_goto): Don't call
	convert_memory_address here.

From-SVN: r219529
2015-01-13 14:44:06 +01:00
Richard Biener
d0ed943ca4 re PR tree-optimization/64406 (ICE: SIGSEGV in estimate_numbers_of_iterations_loop (tree-ssa-loop-niter.c:3453) with custom flags)
2015-01-13  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/64406
	* tree-loop-distibution.c (pass_loop_distribution::execute):
	Reset the SCEV hashtable if we distributed anything.

	* gcc.dg/pr64406.c: New testcase.

From-SVN: r219528
2015-01-13 13:41:46 +00:00
Richard Biener
96bb56b2d7 re PR tree-optimization/64404 (ICE: in vect_get_vec_def_for_operand, at tree-vect-stmts.c:1464 with --param=sccvn-max-alias-queries-per-access=1)
2015-01-13  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/64404
	* tree-vect-stmts.c (vectorizable_load): Reject conflicting
	SLP types for CSEd loads.

	* gcc.dg/vect/pr64404.c: New testcase.

From-SVN: r219527
2015-01-13 12:35:27 +00:00
Iain Sandoe
ebcd09c1c1 update to add myself to Objective-c/c++ maintainers
From-SVN: r219526
2015-01-13 11:23:46 +00:00
Thomas Preud'homme
af410c4c29 re PR tree-optimization/64436 (optimize-bswapdi-3.c fails on aarch64_be-none-elf)
2015-01-13  Thomas Preud'homme  <thomas.preudhomme@arm.com>

    gcc/
    PR tree-optimization/64436
    * tree-ssa-math-opts.c (find_bswap_or_nop_1): Move code performing the
    merge of two symbolic numbers for a bitwise OR to ...
    (perform_symbolic_merge): This. Also fix computation of the range and
    end of the symbolic number corresponding to the result of a bitwise OR.

From-SVN: r219525
2015-01-13 11:23:01 +00:00
Marek Polacek
71aa170d28 Add self as C front end reviewer.
From-SVN: r219523
2015-01-13 09:08:35 +00:00
Richard Biener
a2d429ac5e re PR middle-end/64568 (error: invalid reference prefix)
2014-01-13  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/64568
	* tree-ssa-forwprop.c (pass_forwprop::execute): Properly
	release defs of removed stmts, avoid splitting TARGET_MEM_REFs.

	* g++.dg/torture/pr64568.C: New testcase.

From-SVN: r219520
2015-01-13 08:32:13 +00:00
Jakub Jelinek
0d7a9dbdd2 re PR libgcj/64219 (Rename libgcj-5.0.pc to libgcj-5.pc)
PR libgcj/64219
	* Makefile.am (install-data-local): Use just the major version
	from GCJVERSION instead of major.minor.
	* Makefile.in: Regenerated.

From-SVN: r219519
2015-01-13 09:23:31 +01:00
Chung-Ju Wu
4855be8434 [NDS32] Consider -mcmodel=X in nds32_legitimate_address_p implementation.
gcc/
	* config/nds32/nds32.c (nds32_legitimate_address_p): Consider
	TARGET_CMODEL_LARGE and TARGET_CMODEL_MEDIUM cases.

From-SVN: r219515
2015-01-13 06:06:34 +00:00
Chung-Ju Wu
511a41d799 [NDS32] Implement TARGET_ENCODE_SECTION_INFO to store specific flag in symbol_ref rtx.
gcc/
	* config/nds32/nds32.h (NDS32_SYMBOL_FLAG_RODATA): Define our own
	target-specific symbol_ref flag.
	(NDS32_SYMBOL_REF_RODATA_P): Define it to check if the symbol_ref
	resides in rodata section.
	* config/nds32/nds32.c (TARGET_ENCODE_SECTION_INFO): Define.
	(nds32_encode_section_info): New function.

From-SVN: r219514
2015-01-13 05:59:03 +00:00
Jeff Law
da06754334 MAINTAINERS: Remove Stan Shebs as he has been inactive for a very long time.
* MAINTAINERS: Remove Stan Shebs as he has been inactive for
        a very long time.

From-SVN: r219513
2015-01-12 22:41:11 -07:00
Chung-Ju Wu
1f7b80289a [NDS32] Consider TARGET_CMODEL_LARGE for function call instructions.
gcc/
	* config/nds32/nds32.md (call): Use pseudo instruction bal which
	clobbers TA_REGNUM if large code model is specified.
	(call_register): Likewise.
	(call_immediate): Likewise.
	(call_value): Likewise.
	(call_value_register): Likewise.
	(call_value_immediate): Likewise.

From-SVN: r219512
2015-01-13 05:37:07 +00:00
Chung-Ju Wu
77b7a1ca23 [NDS32] Provide TARGET_CMODEL_[SMALL|MEDIUM|LARGE] to check which code model is specified.
gcc/
	* config/nds32/nds32.h (TARGET_CMODEL_SMALL): New macro.
	(TARGET_CMODEL_MEDIUM): New macro.
	(TARGET_CMODEL_LARGE): New macro.
	* config/nds32/nds32.c (nds32_asm_file_start): Display corresponding
	code model setting in assembly code.

From-SVN: r219511
2015-01-13 05:32:08 +00:00
Chung-Ju Wu
c9eb51a7f7 [NDS32] Remove -mgp-direct/-mno-gp-direct options.
gcc/
	* common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
	Remove MASK_GP_DIRECT flag.
	* config/nds32/nds32.h (MULTILIB_DEFAULTS): Have -mcmodel=medium as
	one of the multilib default options.
	* config/nds32/nds32.opt (mgp-direct): Remove.
	* config/nds32/t-mlibs (MULTILIB_OPTIONS): Use -mcmodel instead of
	-mgp-direct.  We also remove unnecessary -mlittle-endian/-mbig-endian.

From-SVN: r219510
2015-01-13 05:22:25 +00:00
Chung-Ju Wu
fe4c07dc48 [NDS32] Add -mcmodel= option to support different code model.
* config/nds32/nds32.opt (mcmodel): Add new option.
	* config/nds32/nds32-opts.h (nds32_cmodel_type): Add new enum type
	to describe code model.

From-SVN: r219509
2015-01-13 05:17:54 +00:00
Oleg Endo
d9a5f0cc4f re PR target/64479 ([SH] wrong optimization delayed-branch)
gcc/
	PR target/64479
	* rtlanal.c (set_reg_p): Handle SEQUENCE constructs.

From-SVN: r219506
2015-01-13 00:30:57 +00:00
Richard Henderson
ca46eab70b Fix libjava failures on i686-linux
* src/x86/ffi.c (ffi_raw_call): Fill in frame.

From-SVN: r219505
2015-01-12 16:26:31 -08:00
GCC Administrator
b891a9a6d8 Daily bump.
From-SVN: r219503
2015-01-13 00:16:50 +00:00
Kaz Kojima
801881b008 * Add TARGET_ATOMIC_ASSIGN_EXPAND_FENV hook for sh.
From-SVN: r219500
2015-01-12 23:47:58 +00:00
David Malcolm
f6f2b01933 libgccjit: detect various kinds of errors relating to params and locals
gcc/jit/ChangeLog:
	* jit-recording.c (class gcc::jit::rvalue_usage_validator): New.
	(gcc::jit::rvalue_usage_validator::rvalue_usage_validator): New
	ctor.
	(gcc::jit::rvalue_usage_validator::visit): New function.
	(gcc::jit::recording::rvalue::verify_valid_within_stmt): New
	function.
	(gcc::jit::recording::rvalue::set_scope): New function.
	(gcc::jit::recording::function::function): Call set_scope on each
	param, issuing errors for any params that already have a function.
	(gcc::jit::recording::block::add_eval): Return the new statement;
	update the comment given that some error-checking now happens after
	this returns.
	(gcc::jit::recording::block::add_assignment): Likewise.
	(gcc::jit::recording::block::add_assignment_op): Likewise.
	(gcc::jit::recording::block::add_comment): Likewise.
	(gcc::jit::recording::block::end_with_conditional): Likewise.
	(gcc::jit::recording::block::end_with_jump): Likewise.
	(gcc::jit::recording::block::end_with_return): Likewise.
	(gcc::jit::recording::block::validate): Add a comment.
	(gcc::jit::recording::unary_op::visit_children): New function.
	(gcc::jit::recording::binary_op::visit_children): New function.
	(gcc::jit::recording::comparison::visit_children): New function.
	(gcc::jit::recording::cast::visit_children): New function.
	(gcc::jit::recording::call::visit_children): New function.
	(gcc::jit::recording::call_through_ptr::visit_children): New function.
	(gcc::jit::recording::array_access::visit_children): New function.
	(gcc::jit::recording::access_field_of_lvalue::visit_children): New
	function.
	(gcc::jit::recording::access_field_rvalue::visit_children): New
	function.
	(gcc::jit::recording::dereference_field_rvalue::visit_children):
	New function.
	(gcc::jit::recording::dereference_rvalue::visit_children): New
	function.
	(gcc::jit::recording::get_address_of_lvalue::visit_children): New
	function.
	* jit-recording.h: Within namespace gcc::jit::recording...
	(class rvalue_visitor): New.
	(rvalue::rvalue): Initialize m_scope.
	(rvalue::get_loc): New accessor.
	(rvalue::verify_valid_within_stmt): New function.
	(rvalue::visit_children): New pure virtual function.
	(rvalue::set_scope): New function.
	(rvalue::get_scope): New function.
	(rvalue::dyn_cast_param): New function.
	(rvalue::m_scope): New field.
	(param::visit_children): New empty function.
	(param::dyn_cast_param): New function.
	(function::get_loc): New function.
	(block::add_eval): Return the new statement.
	(block::add_assignment): Likewise.
	(block::add_assignment_op): Likewise.
	(block::add_comment): Likewise.
	(block::end_with_conditional): Likewise.
	(block::end_with_jump): Likewise.
	(block::end_with_return): Likewise.
	(global::visit_children): New function.
	(memento_of_new_rvalue_from_const<HOST_TYPE>::visit_children):
	New function.
	(memento_of_new_string_literal::visit_children): New function.
	(unary_op::visit_children): New function.
	(binary_op::visit_children): New function.
	(comparison::visit_children): New function.
	(cast::visit_children): New function.
	(call::visit_children): New function.
	(call_through_ptr::visit_children): New function.
	(array_access::visit_children): New function.
	(access_field_of_lvalue::visit_children): New function.
	(access_field_rvalue::visit_children): New function.
	(dereference_field_rvalue::visit_children): New function.
	(dereference_rvalue::visit_children): New function.
	(get_address_of_lvalue::visit_children): New function.
	(local::local): Call set_scope.
	(local::visit_children): New function.
	(statement::get_block): Make public.
	* libgccjit.c (RETURN_VAL_IF_FAIL_PRINTF5): New macro.
	(RETURN_NULL_IF_FAIL_PRINTF5): New macro.
	(gcc_jit_context_new_function): Verify that each param has
	not yet been used for creating another function.
	(gcc_jit_block_add_eval): After creating the stmt, verify
	that the rvalue expression tree is valid to use within it.
	(gcc_jit_block_add_assignment): Likewise for the lvalue and
	rvalue expression trees.
	(gcc_jit_block_add_assignment_op): Likewise.
	(gcc_jit_block_end_with_conditional): Likewise for the boolval
	expression tree.
	(gcc_jit_block_end_with_return): Likewise for the rvalue
	expression tree.
	(gcc_jit_block_end_with_void_return): Remove return of "void",
	now that block::end_with_return is now non-void.

gcc/testsuite/ChangeLog:
	* jit.dg/test-error-local-used-from-other-function.c: New test
	case.
	* jit.dg/test-error-param-reuse.c: New test case.
	* jit.dg/test-error-param-sharing.c: New test case.
	* jit.dg/test-error-param-used-from-other-function.c: New test
	case.
	* jit.dg/test-error-param-used-without-a-function.c: New test
	case.

From-SVN: r219498
2015-01-12 22:25:37 +00:00
Sandra Loosemore
16ba620346 invoke.texi ([-Wsuggest-attribute=]): Don't use parentheses after a funtion name just to indicate it is a function.
2015-01-12  Sandra Loosemore  <sandra@codesourcery.com>

	gcc/
	* doc/invoke.texi ([-Wsuggest-attribute=]): Don't use parentheses
	after a funtion name just to indicate it is a function.
	([-fsanitize-undefined-trap-on-error]): Likewise.
	([-fdbg-cnt=]): Likewise.
	([-mmemcpy]): Likewise.
	([-mflush-func]): Likewise.
	([-msynci]): Likewise.

From-SVN: r219497
2015-01-12 16:57:54 -05:00
Jonathan Wakely
1b9ad1d9ae re PR libstdc++/64553 (Missing '# ifdef _GLIBCXX_USE_WCHAR_T' in src/c++11/cxx11-shim_facet.cc)
PR libstdc++/64553
	* src/c++11/cxx11-shim_facets.cc: Check for wchar_t support.

From-SVN: r219496
2015-01-12 21:45:50 +00:00
Jonathan Wakely
5e67acc9a0 re PR libstdc++/64560 (building libstdc++ with -fno-rtti fails in new cxx11-shim-facets.cc file)
PR libstdc++/64560
	* src/c++11/cxx11-shim_facets.cc (locale::facet::_M_sso_shim): Check
	for RTTI support.

From-SVN: r219495
2015-01-12 21:45:44 +00:00
Sandra Loosemore
3ae79bfd26 invoke.texi ([-Wbad-function-cast]): Rewrite to avoid confusing example.
2015-01-12  Sandra Loosemore  <sandra@codesourcery.com>

	gcc/
	* doc/invoke.texi ([-Wbad-function-cast]): Rewrite to avoid confusing
	example.

From-SVN: r219494
2015-01-12 16:32:53 -05:00
Jakub Jelinek
737fde1df2 re PR tree-optimization/64563 (ICE with "-Wall -Wextra" at -Os and above on x86_64-linux-gnu)
PR tree-optimization/64563
	* tree-vrp.c (vrp_evaluate_conditional): Check for VR_RANGE
	instead of != VR_VARYING.

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

From-SVN: r219493
2015-01-12 21:48:09 +01:00
Jakub Jelinek
631b8d78b0 re PR target/64513 (ICE: in maybe_record_trace_start, at dwarf2cfi.c:2231 with -mstack-arg-probe)
PR target/64513
	* config/i386/i386.c (ix86_expand_prologue): Add
	REG_FRAME_RELATED_EXPR to %rax and %r10 pushes.

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

From-SVN: r219492
2015-01-12 21:45:38 +01:00
Jakub Jelinek
f51286f21f re PR tree-optimization/64454 (optimize (x%5)%5)
PR tree-optimization/64454
	* tree-vrp.c (simplify_div_or_mod_using_ranges): Optimize
	op0 % op1 into op0 if op0 is in range [-op1 + 1, op1 - 1]
	for signed or [0, op1 - 1] for unsigned modulo.
	(simplify_stmt_using_ranges): Call simplify_div_or_mod_using_ranges
	even if op1 does not satisfy integer_pow2p.

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

From-SVN: r219491
2015-01-12 21:44:32 +01:00
Jakub Jelinek
0199195344 re PR testsuite/64028 (r211599 caused many vectorizer test failures with -fPIC)
PR testsuite/64028
	* gcc.dg/vect/no-section-anchors-vect-31.c: Add dg-add-options
	bind_pic_locally.
	* gcc.dg/vect/no-section-anchors-vect-34.c: Likewise.
	* gcc.dg/vect/no-section-anchors-vect-36.c: Likewise.
	* gcc.dg/vect/no-section-anchors-vect-64.c: Likewise.
	* gcc.dg/vect/no-section-anchors-vect-65.c: Likewise.
	* gcc.dg/vect/no-section-anchors-vect-68.c: Likewise.
	* gcc.dg/vect/no-section-anchors-vect-69.c: Likewise.
	* gcc.dg/vect/slp-25.c: Likewise.
	* gcc.dg/vect/vect-109.c: Likewise.
	* gcc.dg/vect/vect-13.c: Likewise.
	* gcc.dg/vect/vect-17.c: Likewise.
	* gcc.dg/vect/vect-18.c: Likewise.
	* gcc.dg/vect/vect-19.c: Likewise.
	* gcc.dg/vect/vect-20.c: Likewise.
	* gcc.dg/vect/vect-21.c: Likewise.
	* gcc.dg/vect/vect-22.c: Likewise.
	* gcc.dg/vect/vect-27.c: Likewise.
	* gcc.dg/vect/vect-29.c: Likewise.
	* gcc.dg/vect/vect-2-big-array.c: Likewise.
	* gcc.dg/vect/vect-2.c: Likewise.
	* gcc.dg/vect/vect-3.c: Likewise.
	* gcc.dg/vect/vect-4.c: Likewise.
	* gcc.dg/vect/vect-5.c: Likewise.
	* gcc.dg/vect/vect-72.c: Likewise.
	* gcc.dg/vect/vect-73-big-array.c: Likewise.
	* gcc.dg/vect/vect-73.c: Likewise.
	* gcc.dg/vect/vect-77-global.c: Likewise.
	* gcc.dg/vect/vect-78-global.c: Likewise.
	* gcc.dg/vect/vect-7.c: Likewise.
	* gcc.dg/vect/vect-86.c: Likewise.
	* gcc.dg/vect/vect-align-1.c: Likewise.
	* gcc.dg/vect/vect-align-3.c: Likewise.
	* gcc.dg/vect/vect-all-big-array.c: Likewise.
	* gcc.dg/vect/vect-all.c: Likewise.
	* gcc.dg/vect/vect-multitypes-1.c: Likewise.
	* gcc.dg/vect/vect-multitypes-4.c: Likewise.
	* gcc.dg/vect/vect-peel-3.c: Likewise.
	* gcc.dg/vect/vect-peel-4.c: Likewise.
	* gcc.dg/vect/wrapv-vect-7.c: Likewise.

From-SVN: r219490
2015-01-12 21:30:53 +01:00
Jakub Jelinek
aadb701b4c re PR other/64370 (sreal.c:125:23: error: 'exp2' was not declared in this scope)
PR other/64370
	* sreal.c (sreal::to_double): Use ldexp instead of scalbnl.

From-SVN: r219489
2015-01-12 21:30:09 +01:00
Jeff Law
351f160060 re PR target/64461 (bad assembly generated for Coldfire targets)
PR target/64461
        * gcc.target/m68k/pr64461.c: New test.

From-SVN: r219488
2015-01-12 13:19:57 -07:00
David Malcolm
1c35cc2c75 jit-playback.c: fix missing fclose
gcc/jit/ChangeLog:
	* jit-playback.c (gcc::jit::playback::context::read_dump_file):
	Add missing fclose on error-handling path.

From-SVN: r219487
2015-01-12 19:57:05 +00:00
Jeff Law
cfd02f69d7 Add PR marker for last commit
From-SVN: r219484
2015-01-12 12:10:40 -07:00
Jeff Law
1481bdb1a0 m68k.md (truncsiqi2): Disable for TARGET_COLDFIRE.
* config/m68k/m68k.md (truncsiqi2): Disable for TARGET_COLDFIRE.
       (trunchiqi2, truncsihi2): Similarly.

From-SVN: r219483
2015-01-12 12:09:12 -07:00
Jeff Law
f698a4b182 h8300.c (Fpa): Use RTX_FRAME_RELATED_P directly rather than calling F.
* config/h8300/h8300.c (Fpa): Use RTX_FRAME_RELATED_P directly
       rather than calling F.

From-SVN: r219481
2015-01-12 10:26:09 -07:00
David Malcolm
791cfef8e7 jit: API change to gcc_jit_context_new_global
gcc/jit/ChangeLog:
	* docs/cp/topics/expressions.rst (Global variables): Add
	enum gcc_jit_global_kind param to gccjit::context::new_global.
	* docs/topics/expressions.rst (Global variables): Likewise.
	Document the new enum.
	* docs/topics/results.rst (Compilation results): Document
	globals-handling.
	* dummy-frontend.c (jit_langhook_write_globals): Call into the
	playback context's write_global_decls_1 and write_global_decls_2
	before and after calling symtab->finalize_compilation_unit ().
	* jit-playback.c: Include "debug.h".
	(gcc::jit::playback::context::new_global): Add "kind" param and
	use it to set TREE_PUBLIC, TREE_STATIC and DECL_EXTERNAL on the
	underlying VAR_DECL.  Call varpool_node::get_create on the
	VAR_DECL, and add it to m_globals.
	(gcc::jit::playback::context::write_global_decls_1): New function.
	(gcc::jit::playback::context::write_global_decls_2): New function.
	* jit-playback.h (gcc::jit::playback::context::context): Call
	create on m_globals.
	(gcc::jit::playback::context::new_global): Add "kind" param.
	(gcc::jit::playback::context::write_global_decls_1): New function.
	(gcc::jit::playback::context::write_global_decls_2): New function.
	(gcc::jit::playback::context::m_globals): New field.
	* jit-recording.c (gcc::jit::recording::context::context):
	Initialize m_globals.
	(gcc::jit::recording::context::new_global): Add param "kind".
	Add the new global to m_globals.
	(gcc::jit::recording::context::dump_to_file): Dump the globals.
	(gcc::jit::recording::global::replay_into): Add field m_kind.
	(gcc::jit::recording::global::write_to_dump): New override.
	* jit-recording.h (gcc::jit::recording::context::new_global): Add
	param "kind".
	(gcc::jit::recording::context::m_globals): New field.
	(gcc::jit::recording::global::global): Add param kind.
	(gcc::jit::recording::global::write_to_dump): New override.
	(gcc::jit::recording::global::m_kind): New field.
	* jit-result.c (gcc::jit::result::get_global): New function.
	* jit-result.h (gcc::jit::result::get_global): New function.
	* libgccjit++.h (gccjit::context::new_global): Add "kind" param.
	* libgccjit.c (gcc_jit_context_new_global): Likewise.
	(gcc_jit_result_get_global): New API entrypoint.
	* libgccjit.h (gcc_jit_result_get_global): New API entrypoint.
	(enum gcc_jit_global_kind): New enum.
	(gcc_jit_context_new_global): API change: add "kind" param.
	* libgccjit.map (gcc_jit_result_get_global): New symbol.

gcc/testsuite/ChangeLog:
	* jit.dg/test-array-as-pointer.c (create_code): Update call
	to gcc_jit_context_new_global by setting "kind" to
	GCC_JIT_GLOBAL_IMPORTED.
	* jit.dg/test-error-array-as-pointer.c: Likewise.
	* jit.dg/test-expressions.c (make_test_of_get_address): Likewise.
	* jit.dg/test-fuzzer.c (make_random_global): Likewise, but
	setting kind to GCC_JIT_GLOBAL_EXPORTED.
	* jit.dg/test-using-global.c (the_global): Rename to...
	(imported_global): ...this.
	(create_code): Update to test the three kinds of global.
	(verify_code): Likewise.

From-SVN: r219480
2015-01-12 17:14:02 +00:00
Marc Glisse
6c0fcb81da Avoid undefined behavior in gcc.target/i386/pr64291-1.c
PR testsuite/64427
	* gcc.target/i386/pr64291-1.c: Limit to lp64 tarrget.  Avoid
	undefined behavior.
	* gcc.target/i386/pr64291-2.c: Updated.

From-SVN: r219479
2015-01-12 09:08:04 -08:00
Bernd Edlinger
020ca9503b tsan.c (instrument_expr): Use force_gimple_operand.
2015-01-12  Bernd Edlinger  <bernd.edlinger@hotmail.de>

        * tsan.c (instrument_expr): Use force_gimple_operand.
        Use may_be_nonaddressable_p instead of is_gimple_addressable.

From-SVN: r219478
2015-01-12 16:47:11 +00:00
Richard Henderson
b1760f7f91 Merge libffi to upstream commit c82cc159426d8d4402375fa1ae3f045b9cf82e16
From-SVN: r219477
2015-01-12 08:19:59 -08:00
Richard Biener
62e22fcb79 re PR tree-optimization/64530 (Incorrect calculation when assigning to array with -O3)
2015-01-12  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/64530
	* tree-loop-distribution.c (pg_add_dependence_edges): Shuffle
	back dr1.

	* gfortran.dg/pr64530.f90: New testcase.

From-SVN: r219474
2015-01-12 15:37:07 +00:00
Richard Biener
2a58c80212 re PR tree-optimization/64357 (ICE at -Os on x86_64-linux-gnu in check_loop_closed_ssa_use, at tree-ssa-loop-manip.c:579)
2015-01-12  Richard Biener  <rguenther@suse.de>

	PR middle-end/64357
	* tree-cfg.c (gimple_can_merge_blocks_p): Protect simple
	latches properly.

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

From-SVN: r219473
2015-01-12 15:34:37 +00:00
Kyrylo Tkachov
82ac9e4164 [ARM] Use Cortex-A17 tuning parameters for Cortex-A12
* config/arm/arm.c (arm_cortex_a12_tune): Update entries to match
	Cortex-A17 tuning parameters.
	* config/arm/arm-cores.def (cortex-a12): Schedule for cortex-a17.

From-SVN: r219472
2015-01-12 15:14:33 +00:00
Kyrylo Tkachov
57ceb728dc Fix date in gcc/ChangeLog
From-SVN: r219471
2015-01-12 15:09:37 +00:00
Kyrylo Tkachov
8b898d4cbd [ARM] Implement TARGET_SCHED_MACRO_FUSION_PAIR_P
* config/arm/arm-protos.h (tune_params): Add fuseable_ops field.
	* config/arm/arm.c (arm_macro_fusion_p): New function.
	(arm_macro_fusion_pair_p): Likewise.
	(TARGET_SCHED_MACRO_FUSION_P): Define.
	(TARGET_SCHED_MACRO_FUSION_PAIR_P): Likewise.
	(ARM_FUSE_NOTHING): Likewise.
	(ARM_FUSE_MOVW_MOVT): Likewise.
	(arm_slowmul_tune, arm_fastmul_tune, arm_strongarm_tune,
	arm_xscale_tune, arm_9e_tune, arm_v6t2_tune, arm_cortex_tune,
	arm_cortex_a8_tune, arm_cortex_a7_tune, arm_cortex_a15_tune,
	arm_cortex_a53_tune, arm_cortex_a57_tune, arm_cortex_a9_tune,
	arm_cortex_a12_tune, arm_v7m_tune, arm_v6m_tune, arm_fa726te_tune
	arm_cortex_a5_tune): Specify fuseable_ops value.

From-SVN: r219470
2015-01-12 15:09:03 +00:00