Commit Graph

126545 Commits

Author SHA1 Message Date
Paolo Carlini
3d053a5f72 re PR c++/58188 (ICE in gimple_add_tmp_var, at gimplify.c:738)
2013-11-15  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58188
	* g++.dg/cpp0x/nsdmi-template8.C: New.

2013-11-15  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58725
	* g++.dg/cpp0x/nsdmi-template7.C: New.

2013-11-15  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58829
	* g++.dg/cpp0x/nsdmi-template6.C: New.

From-SVN: r204881
2013-11-15 23:51:23 +00:00
Paolo Carlini
6019d86d17 re PR c++/58599 ([c++11] Trouble with non-static data member initializers in templates)
2013-11-15  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/58599
	* g++.dg/cpp0x/nsdmi-template5.C: New.

From-SVN: r204866
2013-11-15 23:17:23 +00:00
Kaz Kojima
d7be3fcdae sh.c (barrier_align): Return 0 when barrier_or_label is null.
* config/sh/sh.c (barrier_align): Return 0 when barrier_or_label
	is null.

From-SVN: r204865
2013-11-15 22:01:33 +00:00
Janne Blomqvist
35f48a901d When file status is unknown, don't set O_CREAT when opening read-only.
2013-11-15  Janne Blomqvist  <jb@gcc.gnu.org>
	    Jerry DeLisle  <jvdelisle@gcc.gnu.org>

	PR fortran/59108
	* io/unix.c (regular_file): Don't set O_CREAT when opening a file
	read-only with unknown status. Mask out O_CREAT when falling back
	to opening read-only if ACTION= is not set and read-write fails.

Co-Authored-By: Jerry DeLisle <jvdelisle@gcc.gnu.org>

From-SVN: r204864
2013-11-16 00:00:36 +02:00
Aldy Hernandez
c02065fca1 Makefile.in (C_COMMON_OBJS): Depend on c-cilkplus.o.
* Makefile.in (C_COMMON_OBJS): Depend on c-cilkplus.o.
	* gimple-pretty-print.c (dump_omp_for): Add case for
	GF_OMP_FOR_KIND_CILKSIMD.
	* gimple.h (enum gf_mask): Restructure entries to add
	GF_OMP_FOR_KIND_CILKSIMD.
	* gimplify.c (is_gimple_stmt): Add case for CILK_SIMD.
	(gimplify_omp_for): Handle CILK_SIMD.
	(gimplify_expr): Add ccase for CILK_SIMD.
	* omp-low.c (extract_omp_for_data): Handle CILK_SIMD.
	(build_outer_var_ref): Same.
	(check_omp_nesting_restrictions): Same.
	(lower_rec_input_clauses): Same.
	(lower_lastprivate_clauses): Same.
	(expand_omp_for): Same.
	(execute_expand_omp): Check flag_enable_cilkplus.
	(execute_lower_omp): Same.
	(diagnose_sb_0): Handle CILK_SIMD.
	(diagnose_omp_structured_block_errors): Check
	flag_enable_cilkplus.
	(setjmp_or_longjmp_p): New.
	(scan_omp_1_stmt): Error on setjmp/longjmp in a simd construct.
	* tree-pretty-print.c (dump_generic_node): Add case for CILK_SIMD.
	* tree.def: Add tree code for CILK_SIMD.

testsuite/
	* c-c++-common/cilk-plus/PS: New directory.
	* g++.dg/cilk-plus/cilk-plus.exp: Run shared tests.
	* g++.dg/dg.exp: Run Cilk Plus tests.
	* gcc.dg/cilk-plus/cilk-plus.exp: Run shared tests.

c-family/
	* c-cilkplus.c: New file.
	* c-common.c (readonly_error): Add location argument.
	* c-common.h (readonly_error): Same.
	(c_finish_cilk_clauses): Protoize.
	(c_check_cilk_loop): Same.
	c-omp.c (c_finish_omp_for): Handle CILK_SIMD nodes.
	Do not fail on error_mark_node.
	Abstract increment canonicalization to here...
	(c_omp_for_incr_canonicalize_ptr): New.
	c-pragma.c (init_pragma): Register "simd" pragma.
	c-pragma.h (enum pragma_kind): Add PRAGMA_CILK_SIMD.
	(enum pragma_cilk_clause): New.

c/
	* c-parser.c (c_parser_cilk_simd): New.
	(c_parser_cilk_verify_simd): New.
	(c_parser_pragma): Add case for PRAGMA_CILK_SIMD.
	(c_parser_omp_for_loop): Add case for NE_EXPR.
	Set c_break_label for CILK_SIMD.
	(c_parser_cilk_clause_vectorlength): New.
	(c_parser_cilk_clause_linear): New.
	(c_parser_cilk_clause_name): New.
	(c_parser_cilk_all_clauses): New.
	* c-typeck.c (build_unary_op): Pass location argument to
	readonly_error.
	(build_modify_expr): Same.
	(build_asm_expr): Same.
	(c_finish_bc_stmt): Error on break/continue in loops.

cp/
	* Make-lang.in (CXX_AND_OBJCXX_OBJS): Depend on cp/cp-cilkplus.o.
	* cp-cilkplus.c: New file.
	* cp-tree.h (cpp_validate_cilk_plus_loop): Protoize.
	* parser.c (cp_parser_cilk_simd): New.
	(cp_debug_parser): Add case for IN_CILK_SIMD_FOR.
	(cp_parser_jump_statement): Same.
	(cp_parser_omp_for_cond): Add new argument.
	Add case for NE_EXPR.
	(cp_parser_omp_for_loop): Pass new argument to
	cp_parser_omp_for_cond.
	Handle CILK_SIMD nodes.
	Abstract initilization code to..
	(cp_parser_omp_for_loop_init): ...here.
	(cp_parser_pragma): Add case for PRAGMA_CILK_SIMD.
	(cp_parser_cilk_simd_vectorlength): New.
	(cp_parser_cilk_simd_linear): New.
	(cp_parser_cilk_simd_clause_name): New.
	(cp_parser_cilk_simd_all_clauses): New.
	(cp_parser_cilk_simd): New.
	* parser.h (IN_CILK_SIMD_FOR): New macro.
	* pt.c (tsubst_expr): Add case for CILK_SIMD.
	* typeck2.c (cxx_readonly_error): Pass location argument to
	readonly_error.

From-SVN: r204863
2013-11-15 21:43:59 +00:00
Bill Schmidt
e19eea7164 altivec.md (UNSPEC_VPERM_X, [...]): Remove.
gcc:

2013-11-15  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>

	* config/rs6000/altivec.md (UNSPEC_VPERM_X, UNSPEC_VPERM_UNS_X):
	Remove.
	(altivec_vperm_<mode>): Revert earlier little endian change.
	(*altivec_vperm_<mode>_internal): Remove.
	(altivec_vperm_<mode>_uns): Revert earlier little endian change.
	(*altivec_vperm_<mode>_uns_internal): Remove.
	* config/rs6000/vector.md (vec_realign_load_<mode>): Revise
	commentary.

gcc/testsuite:

2013-11-15  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>

	* gcc.dg/vmx/3b-15.c: Revise for little endian.

From-SVN: r204862
2013-11-15 21:16:32 +00:00
Jeff Law
6efe83b22e basic-block.h (has_abnormal_or_eh_outgoing_edge): Renamed from has_abnormal_or_outgoing_edge.
* basic-block.h (has_abnormal_or_eh_outgoing_edge): Renamed from
	has_abnormal_or_outgoing_edge.  Check for EH edges as well.
	* gimple-ssa-isolate-paths.c
	(find_implicit_erroneous_behaviour): Corresponding changes.
	Do not check stmt_ends_bb_p or GIMPLE_RETURN anymore.
	(find_explicit_erroneous_behaviour): Likewise.

From-SVN: r204861
2013-11-15 14:11:50 -07:00
Jeff Law
f0d3309e9b ifcvt.c (find_cond_trap): Properly handle case where trap_bb == else_bb.
* ifcvt.c (find_cond_trap): Properly handle case where
	trap_bb == else_bb.

From-SVN: r204856
2013-11-15 11:14:10 -07:00
Steve Ellcey
cb83df668c configure.ac: Do not define HAVE_STRTOLD.
2013-11-15  Steve Ellcey  <sellcey@mips.com>

	* configure.ac: Do not define HAVE_STRTOLD.
	* configure: Regenerate.

From-SVN: r204855
2013-11-15 17:50:28 +00:00
Andreas Schwab
66204992cb picflag.m4 (m68k-*-*): Use default PIC flag.
config/
* picflag.m4 (m68k-*-*): Use default PIC flag.

gcc/
* configure: Regenerate.

libada/
* configure: Regenerate.

libgcc/
* configure: Regenerate.

libiberty/
* configure: Regenerate.

From-SVN: r204854
2013-11-15 17:49:36 +00:00
Ian Lance Taylor
7c0f17db44 runtime: Use runtime_m to get m value after call to runtime_mcall.
From-SVN: r204853
2013-11-15 17:20:25 +00:00
James Greenhalgh
78ec303685 [AArch64] Remove simd_type
gcc/
	* config/aarch64/aarch64-simd.md: Remove simd_type from all
	patterns.
	* config/aarch64/aarch64.md: Likewise, correct "type" attribute
	where it is incorrect or missing.

From-SVN: r204852
2013-11-15 17:05:37 +00:00
Jonathan Wakely
3aaaa651a9 stl_bvector.h (vector<bool>::emplace_back()): LWG 2187: Define.
* include/bits/stl_bvector.h (vector<bool>::emplace_back()): LWG 2187:
	Define.
	(vector<bool>::emplace()): Likewise.
	* testsuite/23_containers/vector/bool/emplace.cc: New.

From-SVN: r204851
2013-11-15 16:34:06 +00:00
Ondřej Bílka
64e1ab1168 build_hacking.xml: Fix documentation typos.
2013-11-15  Ondřej Bílka <neleai@seznam.cz>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

	* doc/xml/manual/build_hacking.xml: Fix documentation typos.
	* doc/xml/manual/configure.xml: Likewise.
	* include/bits/atomic_base.h: Fix typos in comments.
	* include/bits/random.h: Likewise.
	* include/ext/cast.h: Likewise.
	* libsupc++/cxxabi.h: Likewise.
	* testsuite/ext/pb_ds/example/hash_illegal_resize.cc: Likewise.
	* testsuite/tr1/5_numerical_facilities/special_functions/testcase.h:
	Likewise.
	* testsuite/util/exception/safety.h: Likewise.
	* testsuite/util/testsuite_containers.h: Likewise.
	* testsuite/util/testsuite_hooks.cc: Likewise.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r204850
2013-11-15 16:33:59 +00:00
Jonathan Wakely
ff90a89e48 stl_map.h (map): Implement C++11 allocator-aware container requirements.
* include/bits/stl_map.h (map): Implement C++11 allocator-aware
	container requirements.
	* include/bits/stl_multimap.h (multimap): Likewise.
	* include/bits/stl_multiset.h (multiset): Likewise.
	* include/bits/stl_set.h (set): Likewise.
	* include/bits/stl_tree.h (_Rb_tree_node): Use __aligned_buffer and
	add accessors for value.
	(_Rb_tree_iterator, _Rb_tree_const_iterator): Use _Rb_tree_node
	accessors.
	(_Rb_tree): Use allocator_traits and implement support for sets and
	maps the be allocator-aware.
	* include/bits/forward_list.h (_Fwd_list_base::_M_create_node): Do
	not zero-initialize storage buffer.
	* include/bits/hashtable_policy.h (_Hashtable_alloc::_M_allocate_node):
	Likewise.
	* include/bits/stl_vector.h (vector(vector&&, const allocator_type&)):
	Add conditional noexcept specification.
	* doc/xml/manual/status_cxx2011.xml: Update status of containers.
	* testsuite/util/testsuite_allocator.h: Re-indent.
	* testsuite/23_containers/forward_list/allocator/copy.cc: Test
	allocator-extended copy constructor.
	* testsuite/23_containers/unordered_map/allocator/copy.cc: Likewise.
	* testsuite/23_containers/unordered_multimap/allocator/copy.cc:
	Likewise.
	* testsuite/23_containers/unordered_multiset/allocator/copy.cc:
	Likewise.
	* testsuite/23_containers/unordered_set/allocator/copy.cc: Likewise.
	* testsuite/23_containers/vector/allocator/copy.cc: Likewise.
	* testsuite/23_containers/forward_list/allocator/move.cc: New.
	* testsuite/23_containers/unordered_map/allocator/move.cc: New.
	* testsuite/23_containers/unordered_multimap/allocator/move.cc: New.
	* testsuite/23_containers/unordered_multiset/allocator/move.cc: New.
	* testsuite/23_containers/unordered_set/allocator/move.cc: New.
	* testsuite/23_containers/vector/allocator/move.cc: New.
	* testsuite/23_containers/map/allocator/copy.cc: New.
	* testsuite/23_containers/map/allocator/copy_assign.cc: New.
	* testsuite/23_containers/map/allocator/minimal.cc: New.
	* testsuite/23_containers/map/allocator/move.cc: New.
	* testsuite/23_containers/map/allocator/move_assign.cc: New.
	* testsuite/23_containers/map/allocator/noexcept.cc: New.
	* testsuite/23_containers/map/allocator/swap.cc: New.
	* testsuite/23_containers/multimap/allocator/copy.cc: New.
	* testsuite/23_containers/multimap/allocator/copy_assign.cc: New.
	* testsuite/23_containers/multimap/allocator/minimal.cc: New.
	* testsuite/23_containers/multimap/allocator/move.cc: New.
	* testsuite/23_containers/multimap/allocator/move_assign.cc: New.
	* testsuite/23_containers/multimap/allocator/noexcept.cc: New.
	* testsuite/23_containers/multimap/allocator/swap.cc: New.
	* testsuite/23_containers/multiset/allocator/copy.cc: New.
	* testsuite/23_containers/multiset/allocator/copy_assign.cc: New.
	* testsuite/23_containers/multiset/allocator/minimal.cc: New.
	* testsuite/23_containers/multiset/allocator/move.cc: New.
	* testsuite/23_containers/multiset/allocator/move_assign.cc: New.
	* testsuite/23_containers/multiset/allocator/noexcept.cc: New.
	* testsuite/23_containers/multiset/allocator/swap.cc: New.
	* testsuite/23_containers/set/allocator/copy.cc: New.
	* testsuite/23_containers/set/allocator/copy_assign.cc: New.
	* testsuite/23_containers/set/allocator/minimal.cc: New.
	* testsuite/23_containers/set/allocator/move.cc: New.
	* testsuite/23_containers/set/allocator/move_assign.cc: New.
	* testsuite/23_containers/set/allocator/noexcept.cc: New.
	* testsuite/23_containers/set/allocator/swap.cc: New.
	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error line number.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.

From-SVN: r204848
2013-11-15 15:34:14 +00:00
Richard Sandiford
9cc65f15c4 c-pretty-print.c (pp_c_character_constant): Remove unnecessary wchar_type and host_integerp checks.
gcc/c-family/
	* c-pretty-print.c (pp_c_character_constant): Remove unnecessary
	wchar_type and host_integerp checks.

From-SVN: r204847
2013-11-15 14:52:36 +00:00
Richard Sandiford
6b58915bc3 dwarf2out.c (gen_enumeration_type_die): Remove unnecessary host_integerp test.
gcc/
	* dwarf2out.c (gen_enumeration_type_die): Remove unnecessary
	host_integerp test.
	* tree-vect-patterns.c (vect_recog_divmod_pattern): Likewise.
	Use TREE_INT_CST_LOW rather than tree_low_cst when reading the
	constant.
	* fold-const.c (fold_binary_loc): Replace a host_integerp/tree_low_cst
	pair with a TREE_CODE test and TREE_INT_CST_LOW.
	* tree-vect-generic.c (expand_vector_divmod): Likewise.

From-SVN: r204846
2013-11-15 14:52:23 +00:00
Richard Biener
11924f8b48 re PR middle-end/50262 (PTA doesn't disambiguate locally allocated heap objects from pointed to by arguments)
2013-11-15  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/50262
	* tree-ssa-alias.h (struct pt_solution): Split
	vars_contains_global into vars_contains_nonlocal,
	vars_contains_escaped and vars_contains_escaped_heap.
	* tree-ssa-structalias.c (label_visit): Expand comment.
	(handle_lhs_call): Adjust comment.
	(set_uids_in_ptset): Set the new flags appropriately.
	(pt_solution_set): Adjust.
	(pt_solution_set_var): Likewise.
	(pt_solution_ior_into): Likewise.
	(pt_solution_includes_global): Likewise.
	(pt_solutions_intersect_1): Optimize escaped handling.
	(compute_points_to_sets): Remove heap variable globalization.
	(ipa_escaped_pt): Adjust initializer.
	(pass_data_ipa_pta): Do not run TODO_update_ssa.
	* gimple-pretty-print.c (pp_points_to_solution): Print split
	flags.
	* tree-ssa-alias.c (dump_points_to_solution): Likewise.

	* gcc.dg/tree-ssa/alias-28.c: New testcase.
	* gcc.dg/strlenopt-1.c: Adjust.
	* gcc.dg/strlenopt-1f.c: Likewise.

From-SVN: r204845
2013-11-15 14:48:22 +00:00
Richard Biener
e179190c03 tree-loop-distribution.c (tree_loop_distribution): Make sure to distribute all stores.
2013-11-15  Richard Biener  <rguenther@suse.de>

	* tree-loop-distribution.c (tree_loop_distribution): Make sure
	to distribute all stores.

	* gcc.dg/torture/20131115-1.c: New testcase.

From-SVN: r204843
2013-11-15 14:43:52 +00:00
Ulrich Weigand
335123032e * doc/invoke.texi (-mabi=elfv1, -mabi=elfv2): Document.
From-SVN: r204842
2013-11-15 14:21:39 +00:00
Joseph Myers
75a2bcc07f acinclude.m4 (GCC_GLIBC_VERSION_GTE_IFELSE): New configure macro.
* acinclude.m4 (GCC_GLIBC_VERSION_GTE_IFELSE): New configure
	macro.
	* configure.ac: Determine target_header_dir earlier.
	(--with-glibc-version): New configure option.
	Use GCC_GLIBC_VERSION_GTE_IFELSE in enable_gnu_unique_object,
	gcc_cv_libc_provides_ssp and gcc_cv_target_ldbl128 tests.
	* configure: Regenerate.
	* doc/install.texi (--enable-gnu-unique-object): Don't refer to
	native toolchains for default.
	(--with-glibc-version): Document.

From-SVN: r204841
2013-11-15 12:34:28 +00:00
H.J. Lu
9f13879ee8 Add and use System.Linux.time_t for time_t
PR ada/54040
	* s-linux-x32.ads: New file.
	* s-osprim-x32.adb: Likewise.
	* s-linux.ads (time_t): New type.
	* s-linux-alpha.ads (time_t):  Likewise.
	* s-linux-hppa.ads (time_t):  Likewise.
	* s-linux-mipsel.ads (time_t):  Likewise.
	* s-linux-sparc.ads (time_t):  Likewise.
	* s-osinte-linux.ads (time_t): Mark it private.  Replace long
	with System.Linux.time_t.
	(timespec): Replace long with time_t.
	* s-osinte-posix.adb (To_Timespec): Likewise.
	* s-taprop-linux.adb (timeval): Replace C.long with
	System.OS_Interface.time_t.
	* gcc-interface/Makefile.in (LIBGNAT_TARGET_PAIRS): Replace
	s-linux.ads with s-linux-x32.ads, s-osprim-posix.adb with
	s-osprim-x32.adb for x32.

From-SVN: r204840
2013-11-15 04:06:25 -08:00
Eric Botcazou
d877729c89 * fold-const.c (fold_binary_loc) <comparisons>: Reuse local variable.
From-SVN: r204839
2013-11-15 11:07:40 +00:00
Kostya Serebryany
c8e1377bf9 fix PR sanitizer/58994
From-SVN: r204838
2013-11-15 10:31:14 +00:00
Uros Bizjak
d1c369c21e lto-streamer-in.c (input function): Call cgraph_create_node if cgraph_get_node failed.
* lto-streamer-in.c (input function): Call cgraph_create_node if
	cgraph_get_node failed.

From-SVN: r204836
2013-11-15 09:46:54 +01:00
Joseph Myers
54848ff84b ucnid-9.c: New test.
gcc/testsuite:
	* gcc.dg/cpp/ucnid-9.c: New test.

libcpp:
	* ucnid.tab: Mark C99 digits as [C99DIG].
	* makeucnid.c (read_ucnid): Handle [C99DIG].
	(read_table): Don't check for digit characters.
	* ucnid.h: Regenerate.

From-SVN: r204835
2013-11-15 02:15:26 +00:00
GCC Administrator
4976d4f65a Daily bump.
From-SVN: r204833
2013-11-15 00:16:47 +00:00
Eric Botcazou
ee2e846215 cfgexpand.c (defer_stack_allocation): When optimization is enabled...
* cfgexpand.c (defer_stack_allocation): When optimization is enabled,
	defer allocation of DECL_IGNORED_P variables at toplevel unless really
	small.  Factorize size threshold computation from the existing one.
	(expand_used_vars): Refine comment.

From-SVN: r204830
2013-11-14 23:58:39 +00:00
H.J. Lu
ed1fc0bc29 Revert the last change
* gnat.dg/specs/addr1.ads: Revert the last change.
	* gnat.dg/specs/atomic1.ads: Likewise.

From-SVN: r204829
2013-11-14 14:39:21 -08:00
Ian Lance Taylor
37512c0399 runtime: Don't use filename without '/' for backtrace library.
Fixes http://golang.org/issue/6715.

From-SVN: r204828
2013-11-14 22:31:29 +00:00
Ian Lance Taylor
58c55a329a compiler: Use backend interface for comparisons.
From-SVN: r204827
2013-11-14 22:13:41 +00:00
H.J. Lu
1726bd6ea3 Include gimple.h and pointer-set.h in gcc-interface/trans.c
* gcc-interface/trans.c: Include gimple.h and pointer-set.h.

From-SVN: r204826
2013-11-14 14:04:04 -08:00
Cong Hou
93bdc3edf1 tree-vectorizer.h (struct dr_with_seg_len): Remove the base address field as it can be obtained from dr.
2013-11-14  Cong Hou  <congh@google.com>

    * tree-vectorizer.h (struct dr_with_seg_len): Remove the base
    address field as it can be obtained from dr.  Rename the struct.
    * tree-vect-data-refs.c (comp_dr_with_seg_len_pair): Consider
    steps of data references during sort.
    (vect_prune_runtime_alias_test_list): Adjust with the change to
    struct dr_with_seg_len.
    * tree-vect-loop-manip.c (vect_create_cond_for_alias_checks):
    Adjust with the change to struct dr_with_seg_len.

2013-11-14  Cong Hou  <congh@google.com>

    * gcc.dg/vect/vect-alias-check.c: Update.

From-SVN: r204822
2013-11-14 15:59:47 -05:00
Jeff Law
5e94175fa5 basic-block.h (has_abnormal_outgoing_edge_p): Moved here from...
* basic-block.h (has_abnormal_outgoing_edge_p): Moved here from...
	* tree-inline.c (has_abnormal_outgoing_edge_p): Remove.
	* gimple-ssa-isolate-paths.c: Include tree-cfg.h.
	(find_implicit_erroneous_behaviour): If a block has abnormal outgoing
	edges, then ignore it.  If the statement exhibiting erroneous
	behaviour ends basic blocks, with the exception of GIMPLE_RETURNs,
	then we can not optimize.
	(find_explicit_erroneous_behaviour): Likewise.

From-SVN: r204821
2013-11-14 13:57:38 -07:00
Ian Lance Taylor
01ef823cdd net: On Solaris use Darwin keepalive code.
From-SVN: r204819
2013-11-14 20:19:51 +00:00
Paolo Carlini
4699e99ae8 re PR c++/57887 (nested non-type template parameters not declared in this scope)
/cp
2013-11-14  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/57887
	* parser.c (cp_parser_late_parsing_nsdmi): Call
	maybe_begin_member_template_processing.
	* pt.c (maybe_begin_member_template_processing): Handle NSDMIs.
	(inline_needs_template_parms): Adjust.

/testsuite
2013-11-14  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/57887
	* g++.dg/cpp0x/nsdmi-template3.C: New.
	* g++.dg/cpp0x/nsdmi-template4.C: Likewise.

From-SVN: r204818
2013-11-14 20:16:51 +00:00
Ian Lance Taylor
03a231f752 runtime: Add netpoll code that uses select.
Required for Solaris support.

From-SVN: r204817
2013-11-14 20:15:04 +00:00
Ian Lance Taylor
7d608db296 runtime: Fix GC flag in when allocating memory from cgo.
From-SVN: r204815
2013-11-14 20:04:32 +00:00
Andrew MacLeod
18f429e29c gimplify-be.h: New file.
* gimplify-be.h:  New file.  Add prototypes.
	* gimplify.h: Don't include gimple.h.
	(struct gimplify_hasher, struct gimplify_ctx, is_gimple_sizepos,
	gimplify_hasher::hash, gimplify_hasher::equal): Relocate from gimple.h.
	* gimple.h (struct gimplify_hasher, gimplify_hasher::hash,
	gimplify_hasher::equal, struct gimplify_ctx, is_gimple_sizepos): Move
	to gimplify.h.
	(enum gsi_iterator_update): Move to gimple-iterator.h.
	* gimple-iterator.h (enum gsi_iterator_update): Relocate from gimple.h.
	* gimplify-be.c: New File.
	(force_gimple_operand_1, force_gimple_operand,
	force_gimple_operand_gsi_1, force_gimple_operand_gsi): Relocate from
	gimplify.c.
	* gimplify.c (force_gimple_operand_1, force_gimple_operand,
	force_gimple_operand_gsi_1, force_gimple_operand_gsi): Move to
	gimplify-be.c.
	* Makefile.in (OBJS): Add gimplify-be.o
	* asan.c: Include only gimplify.h, gimplify-be.h, and/or gimple.h as
	required.
	* cfgloopmanip.c: Likewise.
	* cgraphunit.c: Likewise.
	* cilk-common.c: Likewise.
	* fold-const.c: Likewise.
	* function.c: Likewise.
	* gimple-expr.c: Likewise.
	* gimple-fold.c: Likewise.
	* gimple-ssa-strength-reduction.c: Likewise.
	* gimple.c: Likewise.
	* graphite-clast-to-gimple.c: Likewise.
	* graphite-sese-to-poly.c: Likewise.
	* ipa-prop.c: Likewise.
	* ipa-split.c: Likewise.
	* ipa.c: Likewise.
	* langhooks.c: Likewise.
	* omp-low.c: Likewise.
	* sese.c: Likewise.
	* stor-layout.c: Likewise.
	* targhooks.c: Likewise.
	* trans-mem.c: Likewise.
	* tree-affine.c: Likewise.
	* tree-cfg.c: Likewise.
	* tree-cfgcleanup.c: Likewise.
	* tree-complex.c: Likewise.
	* tree-if-conv.c: Likewise.
	* tree-inline.c: Likewise.
	* tree-loop-distribution.c: Likewise.
	* tree-nested.c: Likewise.
	* tree-parloops.c: Likewise.
	* tree-predcom.c: Likewise.
	* tree-profile.c: Likewise.
	* tree-scalar-evolution.c: Likewise.
	* tree-sra.c: Likewise.
	* tree-ssa-address.c: Likewise.
	* tree-ssa-ccp.c: Likewise.
	* tree-ssa-dce.c: Likewise.
	* tree-ssa-forwprop.c: Likewise.
	* tree-ssa-ifcombine.c: Likewise.
	* tree-ssa-loop-im.c: Likewise.
	* tree-ssa-loop-ivopts.c: Likewise.
	* tree-ssa-loop-manip.c: Likewise.
	* tree-ssa-loop-niter.c: Likewise.
	* tree-ssa-loop-prefetch.c: Likewise.
	* tree-ssa-loop-unswitch.c: Likewise.
	* tree-ssa-math-opts.c: Likewise.
	* tree-ssa-phiopt.c: Likewise.
	* tree-ssa-phiprop.c: Likewise.
	* tree-ssa-pre.c: Likewise.
	* tree-ssa-propagate.c: Likewise.
	* tree-ssa-reassoc.c: Likewise.
	* tree-ssa-sccvn.c: Likewise.
	* tree-ssa-strlen.c: Likewise.
	* tree-ssa.c: Likewise.
	* tree-switch-conversion.c: Likewise.
	* tree-tailcall.c: Likewise.
	* tree-vect-data-refs.c: Likewise.
	* tree-vect-generic.c: Likewise.
	* tree-vect-loop-manip.c: Likewise.
	* tree-vect-loop.c: Likewise.
	* tree-vect-patterns.c: Likewise.
	* tree-vect-stmts.c: Likewise.
	* tree.c: Likewise.
	* tsan.c: Likewise.
	* value-prof.c: Likewise.
	* config/aarch64/aarch64.c: Likewise.
	* config/alpha/alpha.c: Likewise.
	* config/darwin.c: Likewise.
	* config/i386/i386.c: Likewise.
	* config/ia64/ia64.c: Likewise.
	* config/mep/mep.c: Likewise.
	* config/mips/mips.c: Likewise.
	* config/rs6000/rs6000.c: Likewise.
	* config/s390/s390.c: Likewise.
	* config/sh/sh.c: Likewise.
	* config/sparc/sparc.c: Likewise.
	* config/spu/spu.c: Likewise.
	* config/stormy16/stormy16.c: Likewise.
	* config/tilegx/tilegx.c: Likewise.
	* config/tilepro/tilepro.c: Likewise.
	* config/xtensa/xtensa.c: Likewise.

	* c/c-typeck.c: Include only gimplify.h and gimple.h as needed.
	* c-family/c-common.c: Likewise.
	* c-family/c-gimplify.c: Likewise.
	* c-family/cilk.c: Likewise.

	* cp/class.c: Include only gimplify.h and gimple.h as needed.
	* cp/cp-gimplify.c: Likewise.
	* cp/error.c: Likewise.
	* cp/init.c: Likewise.
	* cp/optimize.c: Likewise.
	* cp/pt.c: Likewise.
	* cp/semantics.c: Likewise.
	* cp/tree.c: Likewise.
	* cp/vtable-class-hierarchy.c: Likewise.

	* fortran/trans-expr.c: Include only gimplify.h and gimple.h as needed.
	* fortran/trans-openmp.c: Likewise.

	* go/go-lang.c: Include only gimplify.h and gimple.h as needed.

	* java/java-gimplify.c: Include only gimplify.h and gimple.h as needed.

	* objc/objc-act.c: Include only gimplify.h and gimple.h as needed.

From-SVN: r204812
2013-11-14 19:39:38 +00:00
Joern Rennecke
6495f8e61f arc.md (doloop_begin_i): Remove extra alignment; use (.&-4) idiom.
* config/arc/arc.md (doloop_begin_i): Remove extra alignment;
	use (.&-4) idiom.

From-SVN: r204810
2013-11-14 18:53:25 +00:00
Ulrich Weigand
5b101aaed1 sysv4le.h (LINUX64_DEFAULT_ABI_ELFv2): Define.
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/sysv4le.h (LINUX64_DEFAULT_ABI_ELFv2): Define.

From-SVN: r204809
2013-11-14 18:51:41 +00:00
Ulrich Weigand
b54214fe22 rs6000.h (RS6000_SAVE_AREA): Handle ABI_ELFv2.
gcc/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/rs6000.h (RS6000_SAVE_AREA): Handle ABI_ELFv2.
	(RS6000_SAVE_TOC): Remove.
	(RS6000_TOC_SAVE_SLOT): New macro.
	* config/rs6000/rs6000.c (rs6000_parm_offset): New function.
	(rs6000_parm_start): Use it.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_emit_prologue): Use RS6000_TOC_SAVE_SLOT.
	(rs6000_emit_epilogue): Likewise.
	(rs6000_call_aix): Likewise.
	(rs6000_output_function_prologue): Do not save/restore r11
	around calling _mcount for ABI_ELFv2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/rs6000-protos.h (rs6000_reg_parm_stack_space):
	Add prototype.
	* config/rs6000/rs6000.h (RS6000_REG_SAVE): Remove.
	(REG_PARM_STACK_SPACE): Call rs6000_reg_parm_stack_space.
	* config/rs6000/rs6000.c (rs6000_parm_needs_stack): New function.
	(rs6000_function_parms_need_stack): Likewise.
	(rs6000_reg_parm_stack_space): Likewise.
	(rs6000_function_arg): Do not replace BLKmode by Pmode when
	returning a register argument.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Michael Gschwind  <mkg@us.ibm.com>

	* config/rs6000/rs6000.h (FP_ARG_MAX_RETURN): New macro.
	(ALTIVEC_ARG_MAX_RETURN): Likewise.
	(FUNCTION_VALUE_REGNO_P): Use them.
	* config/rs6000/rs6000.c (TARGET_RETURN_IN_MSB): Define.
	(rs6000_return_in_msb): New function.
	(rs6000_return_in_memory): Handle ELFv2 homogeneous aggregates.
	Handle aggregates of up to 16 bytes for ELFv2.
	(rs6000_function_value): Handle ELFv2 homogeneous aggregates.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Michael Gschwind  <mkg@us.ibm.com>

	* config/rs6000/rs6000.h (AGGR_ARG_NUM_REG): Define.
	* config/rs6000/rs6000.c (rs6000_aggregate_candidate): New function.
	(rs6000_discover_homogeneous_aggregate): Likewise.
	(rs6000_function_arg_boundary): Handle homogeneous aggregates.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.
	(rs6000_psave_function_arg): Handle BLKmode arguments.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Michael Gschwind  <mkg@us.ibm.com>

	* config/rs6000/rs6000.h (AGGR_ARG_NUM_REG): Define.
	* config/rs6000/rs6000.c (rs6000_aggregate_candidate): New function.
	(rs6000_discover_homogeneous_aggregate): Likewise.
	(rs6000_function_arg_boundary): Handle homogeneous aggregates.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.
	(rs6000_psave_function_arg): Handle BLKmode arguments.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (machine_function): New member
	r2_setup_needed.
	(rs6000_emit_prologue): Set r2_setup_needed if necessary.
	(rs6000_output_mi_thunk): Set r2_setup_needed.
	(rs6000_output_function_prologue): Output global entry point
	prologue and local entry point marker if needed for ABI_ELFv2.
	Output -mprofile-kernel code here.
	(output_function_profiler): Do not output -mprofile-kernel
	code here; moved to rs6000_output_function_prologue.
	(rs6000_file_start): Output ".abiversion 2" for ABI_ELFv2.

	(rs6000_emit_move): Do not handle dot symbols for ABI_ELFv2.
	(rs6000_output_function_entry): Likewise.
	(rs6000_assemble_integer): Likewise.
	(rs6000_elf_encode_section_info): Likewise.
	(rs6000_elf_declare_function_name): Do not create dot symbols
	or .opd section for ABI_ELFv2.

	(rs6000_trampoline_size): Update for ABI_ELFv2 trampolines.
	(rs6000_trampoline_init): Likewise.
	(rs6000_elf_file_end): Call file_end_indicate_exec_stack
	for ABI_ELFv2.

	(rs6000_call_aix): Handle ELFv2 indirect calls.  Do not check
	for function descriptors in ABI_ELFv2.

	* config/rs6000/rs6000.md ("*call_indirect_aix<mode>"): Support
	on ABI_AIX only, not ABI_ELFv2.
	("*call_value_indirect_aix<mode>"): Likewise.
	("*call_indirect_elfv2<mode>"): New pattern.
	("*call_value_indirect_elfv2<mode>"): Likewise.

	* config/rs6000/predicates.md ("symbol_ref_operand"): Do not
	check for function descriptors in ABI_ELFv2.
	("current_file_function_operand"): Likewise.

	* config/rs6000/ppc-asm.h [__powerpc64__ && _CALL_ELF == 2]:
	(toc): Undefine.
	(FUNC_NAME): Define ELFv2 variant.
	(JUMP_TARGET): Likewise.
	(FUNC_START): Likewise.
	(HIDDEN_FUNC): Likewise.
	(FUNC_END): Likeiwse.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config.gcc [powerpc*-*-* | rs6000-*-*]: Support --with-abi=elfv1
	and --with-abi=elfv2.
	* config/rs6000/option-defaults.h (OPTION_DEFAULT_SPECS): Add "abi".
	* config/rs6000/rs6000.opt (mabi=elfv1): New option.
	(mabi=elfv2): Likewise.
	* config/rs6000/rs6000-opts.h (enum rs6000_abi): Add ABI_ELFv2.
	* config/rs6000/linux64.h (DEFAULT_ABI): Do not hard-code to AIX_ABI
	if !RS6000_BI_ARCH.
	(ELFv2_ABI_CHECK): New macro.
	(SUBSUBTARGET_OVERRIDE_OPTIONS): Use it to decide whether to set
	rs6000_current_abi to ABI_AIX or ABI_ELFv2.
	(GLIBC_DYNAMIC_LINKER64): Support ELFv2 ld.so version.
	* config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Predefine
	_CALL_ELF and __STRUCT_PARM_ALIGN__ if appropriate.

	* config/rs6000/rs6000.c (rs6000_debug_reg_global): Handle ABI_ELFv2.
	(debug_stack_info): Likewise.
	(rs6000_file_start): Treat ABI_ELFv2 the same as ABI_AIX.
	(rs6000_legitimize_tls_address): Likewise.
	(rs6000_conditional_register_usage): Likewise.
	(rs6000_emit_move): Likewise.
	(init_cumulative_args): Likewise.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.
	(rs6000_output_function_entry): Likewise.
	(rs6000_assemble_integer): Likewise.
	(rs6000_savres_strategy): Likewise.
	(rs6000_stack_info): Likewise.
	(rs6000_function_ok_for_sibcall): Likewise.
	(rs6000_emit_load_toc_table): Likewise.
	(rs6000_savres_routine_name): Likewise.
	(ptr_regno_for_savres): Likewise.
	(rs6000_emit_prologue): Likewise.
	(rs6000_emit_epilogue): Likewise.
	(rs6000_output_function_epilogue): Likewise.
	(output_profile_hook): Likewise.
	(output_function_profiler): Likewise.
	(rs6000_trampoline_size): Likewise.
	(rs6000_trampoline_init): Likewise.
	(rs6000_elf_output_toc_section_asm_op): Likewise.
	(rs6000_elf_encode_section_info): Likewise.
	(rs6000_elf_reloc_rw_mask): Likewise.
	(rs6000_elf_declare_function_name): Likewise.
	(rs6000_function_arg_boundary): Treat ABI_ELFv2 the same as ABI_AIX,
	except that rs6000_compat_align_parm is always assumed false.
	(rs6000_gimplify_va_arg): Likewise.
	(rs6000_call_aix): Update comment.
	(rs6000_sibcall_aix): Likewise.
	* config/rs6000/rs6000.md ("tls_gd_aix<TLSmode:tls_abi_suffix>"):
	Treat ABI_ELFv2 the same as ABI_AIX.
	("*tls_gd_call_aix<TLSmode:tls_abi_suffix>"): Likewise.
	("tls_ld_aix<TLSmode:tls_abi_suffix>"): Likewise.
	("*tls_ld_call_aix<TLSmode:tls_abi_suffix>"): Likewise.
	("load_toc_aix_si"): Likewise.
	("load_toc_aix_di"): Likewise.
	("call"): Likewise.
	("call_value"): Likewise.
	("*call_local_aix<mode>"): Likewise.
	("*call_value_local_aix<mode>"): Likewise.
	("*call_nonlocal_aix<mode>"): Likewise.
	("*call_value_nonlocal_aix<mode>"): Likewise.
	("*call_indirect_aix<mode>"): Likewise.
	("*call_value_indirect_aix<mode>"): Likewise.
	("sibcall"): Likewise.
	("sibcall_value"): Likewise.
	("*sibcall_aix<mode>"): Likewise.
	("*sibcall_value_aix<mode>"): Likewise.
	* config/rs6000/predicates.md ("symbol_ref_operand"): Likewise.
	("current_file_function_operand"): Likewise.

gcc/testsuite/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* gcc.target/powerpc/ppc64-abi-1.c (stack_frame_t): Remove
	compiler and linker field if _CALL_ELF == 2.
	* gcc.target/powerpc/ppc64-abi-2.c (stack_frame_t): Likewise.
	* gcc.target/powerpc/ppc64-abi-dfp-1.c (stack_frame_t): Likewise.
	* gcc.dg/stack-usage-1.c (SIZE): Update value for _CALL_ELF == 2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* gcc.target/powerpc/ppc64-abi-dfp-1.c (FUNC_START): New macro.
	(WRAPPER): Use it.
	* gcc.target/powerpc/no-r11-1.c: Skip on powerpc_elfv2.
	* gcc.target/powerpc/no-r11-2.c: Skip on powerpc_elfv2.
	* gcc.target/powerpc/no-r11-3.c: Skip on powerpc_elfv2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* lib/target-supports.exp (check_effective_target_powerpc_elfv2):
	New function.
	* gcc.target/powerpc/pr57949-1.c: Disable for powerpc_elfv2.
	* gcc.target/powerpc/pr57949-2.c: Likewise.

libgcc/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/linux-unwind.h (TOC_SAVE_SLOT): Define.
	(frob_update_context): Use it.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/tramp.S [__powerpc64__ && _CALL_ELF == 2]:
	(trampoline_initial): Provide ELFv2 variant.
	(__trampoline_setup): Likewise.

	* config/rs6000/linux-unwind.h (frob_update_context): Do not
	check for AIX indirect function call sequence if _CALL_ELF == 2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/linux-unwind.h (get_regs): Do not support
	old kernel versions if _CALL_ELF == 2.
	(frob_update_context): Do not support PLT stub variants only
	generated by old linkers if _CALL_ELF == 2.

libitm/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/powerpc/sjlj.S [__powerpc64__ && _CALL_ELF == 2]:
	(FUNC): Define ELFv2 variant.
	(END): Likewise.
	(HIDDEN): Likewise.
	(CALL): Likewise.
	(BASE): Likewise.
	(LR_SAVE): Likewise.

libstdc++/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* scripts/extract_symvers.in: Ignore <localentry: > fields
	in readelf --symbols output.


Co-Authored-By: Alan Modra <amodra@gmail.com>
Co-Authored-By: Michael Gschwind <mkg@us.ibm.com>

From-SVN: r204808
2013-11-14 18:50:48 +00:00
Ulrich Weigand
140f2c812c rs6000.c (rs6000_arg_partial_bytes): Simplify logic by making use of the fact that for vector / floating point...
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (rs6000_arg_partial_bytes): Simplify logic
	by making use of the fact that for vector / floating point arguments
	passed both in VRs/FPRs and in the fixed parameter area, the partial
	bytes mechanism is in fact not used.

From-SVN: r204807
2013-11-14 18:40:12 +00:00
Ulrich Weigand
98eefff6bc rs6000.c (rs6000_psave_function_arg): New function.
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (rs6000_psave_function_arg): New function.
	(rs6000_finish_function_arg): Likewise.
	(rs6000_function_arg): Use rs6000_psave_function_arg and
	rs6000_finish_function_arg to handle both vector and floating
	point arguments that are also passed in GPRs / the stack.

From-SVN: r204806
2013-11-14 18:39:14 +00:00
Ulrich Weigand
abc991e700 rs6000.c (USE_FP_FOR_ARG_P): Remove TYPE argument.
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (USE_FP_FOR_ARG_P): Remove TYPE argument.
	(USE_ALTIVEC_FOR_ARG_P): Likewise.
	(rs6000_darwin64_record_arg_advance_recurse): Update uses.
	(rs6000_function_arg_advance_1):Likewise.
	(rs6000_darwin64_record_arg_recurse): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.

From-SVN: r204805
2013-11-14 18:38:08 +00:00
Ulrich Weigand
008e32c018 rs6000.c (rs6000_option_override_internal): Replace "DEFAULT_ABI != ABI_AIX" test by testing for ABI_V4 or ABI_DARWIN.
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (rs6000_option_override_internal): Replace
	"DEFAULT_ABI != ABI_AIX" test by testing for ABI_V4 or ABI_DARWIN.
	(rs6000_savres_strategy): Likewise.
	(rs6000_return_addr): Likewise.
	(rs6000_emit_load_toc_table): Replace "DEFAULT_ABI != ABI_AIX" by
	testing for ABI_V4 (since ABI_DARWIN is impossible here).
	(rs6000_emit_prologue): Likewise.
	(legitimate_lo_sum_address_p): Simplify DEFAULT_ABI test.
	(rs6000_elf_declare_function_name): Remove duplicated test.
	* config/rs6000/rs6000.md ("load_toc_v4_PIC_1"): Explicitly test
	for ABI_V4 (instead of "DEFAULT_ABI != ABI_AIX" test).
	("load_toc_v4_PIC_1_normal"): Likewise.
	("load_toc_v4_PIC_1_476"): Likewise.
	("load_toc_v4_PIC_1b"): Likewise.
	("load_toc_v4_PIC_1b_normal"): Likewise.
	("load_toc_v4_PIC_1b_476"): Likewise.
	("load_toc_v4_PIC_2"): Likewise.
	("load_toc_v4_PIC_3b"): Likewise.
	("load_toc_v4_PIC_3c"): Likewise.
	* config/rs6000/rs6000.h (RS6000_REG_SAVE): Simplify DEFAULT_ABI test.
	(RS6000_SAVE_AREA): Likewise.
	(FP_ARG_MAX_REG): Likewise.
	(RETURN_ADDRESS_OFFSET): Likewise.
	* config/rs6000/sysv.h (TARGET_TOC): Test for ABI_V4 instead
	of ABI_AIX.
	(SUBTARGET_OVERRIDE_OPTIONS): Likewise.
	(MINIMAL_TOC_SECTION_ASM_OP): Likewise.

From-SVN: r204804
2013-11-14 18:36:48 +00:00
Ulrich Weigand
f90f960ca8 rs6000.c (rs6000_call_indirect_aix): Rename to ...
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (rs6000_call_indirect_aix): Rename to ...
	(rs6000_call_aix): ... this.  Handle both direct and indirect calls.
	Create call insn directly instead of via various gen_... routines.
	Mention special registers used by the call in CALL_INSN_FUNCTION_USAGE.
	(rs6000_sibcall_aix): New function.
	* config/rs6000/rs6000.md (TOC_SAVE_OFFSET_32BIT): Remove.
	(TOC_SAVE_OFFSET_64BIT): Likewise.
	(AIX_FUNC_DESC_TOC_32BIT): Likewise.
	(AIX_FUNC_DESC_TOC_64BIT): Likewise.
	(AIX_FUNC_DESC_SC_32BIT): Likewise.
	(AIX_FUNC_DESC_SC_64BIT): Likewise.
	("call" expander): Call rs6000_call_aix.
	("call_value" expander): Likewise.
	("call_indirect_aix<ptrsize>"): Replace this pattern ...
	("call_indirect_aix<ptrsize>_nor11"): ... and this pattern ...
	("*call_indirect_aix<mode>"): ... by this insn pattern.
	("call_value_indirect_aix<ptrsize>"): Replace this pattern ...
	("call_value_indirect_aix<ptrsize>_nor11"): ... and this pattern ...
	("*call_value_indirect_aix<mode>"): ... by this insn pattern.
	("*call_nonlocal_aix32", "*call_nonlocal_aix64"): Replace by ...
	("*call_nonlocal_aix<mode>"): ... this pattern.
	("*call_value_nonlocal_aix32", "*call_value_nonlocal_aix64"): Replace
	("*call_value_nonlocal_aix<mode>"): ... by this pattern.
	("*call_local_aix<mode>"): New insn pattern.
	("*call_value_local_aix<mode>"): Likewise.
	("sibcall" expander): Call rs6000_sibcall_aix.
	("sibcall_value" expander): Likewise.  Move earlier in file.
	("*sibcall_nonlocal_aix<mode>"): Replace by ...
	("*sibcall_aix<mode>"): ... this pattern.
	("*sibcall_value_nonlocal_aix<mode>"): Replace by ...
	("*sibcall_value_aix<mode>"): ... this pattern.
	* config/rs6000/rs6000-protos.h (rs6000_call_indirect_aix): Remove.
	(rs6000_call_aix): Add prototype.
	(rs6000_sibcall_aix): Likewise.

From-SVN: r204803
2013-11-14 18:32:48 +00:00
Ulrich Weigand
4f883df12f Forgot to add file in last commit.
From-SVN: r204802
2013-11-14 18:30:19 +00:00
Jakub Jelinek
8c8b21e4f7 re PR sanitizer/59122 (libsanitizer merge from upstream r191666 causes duplicate symbol errors)
PR sanitizer/59122
	* asan.c (asan_emit_stack_protection): Ensure -fsection-anchors
	isn't confused by the artificial decl.

From-SVN: r204801
2013-11-14 19:28:43 +01:00
Ulrich Weigand
13e0981af5 linux-unwind.h (ppc_fallback_frame_state): Correct location of CR save area for 64-bit little-endian systems.
2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/linux-unwind.h (ppc_fallback_frame_state): Correct
	location of CR save area for 64-bit little-endian systems.


Co-Authored-By: Alan Modra <amodra@gmail.com>

From-SVN: r204800
2013-11-14 18:25:33 +00:00