Commit Graph

103736 Commits

Author SHA1 Message Date
Nathan Froyd
8ac7fdcb39 config.gcc (arm*-*-linux-*eabi): Add bpabi.h from libgcc.
gcc/
	* config.gcc (arm*-*-linux-*eabi) <tm_file>: Add bpabi.h from
	libgcc.
	(arm*-*-uclinux*eabi) <tm_file>: Likewise.
	(arm*-*-eabi*) <tm_file>: Likewise.
	(frv-*-elf) <tm_file>: Add frv-abi.h from libgcc.
	(frv-*-*linux*) <tm_file>: Likewise.
	* config/arm/bpabi.h: Delete DECLARE_LIBRARY_RENAMES stanzas
	and associated helper macros.
	* config/frv/frv-abi.h: Delete.

libgcc/
	* config/arm/bpabi.h: New file.
	* config/frv/frv-abi.h: New file.

From-SVN: r165463
2010-10-14 12:35:43 +00:00
Richard Guenther
1e85e7204d re PR c++/44561 (using nullptr_t with -flto/-fwhopr causes ICE: tree code 'lang_type' is not supported in gimple streams)
2010-10-14  Richard Guenther  <rguenther@suse.de>

	PR lto/44561
	* tree.def (NULLPTR_TYPE): New tree code.
	* dbxout.c (dbxout_type): Handle NULLPTR_TYPE.
	* dwarf2out.c (is_base_type): Likewise.
	(gen_type_die_with_usage): Likewise.
	* sdbout.c (plain_type_1): Likewise.
	* tree.c (build_int_cst_wide): Likewise.
	* gimple.c (gimple_types_compatible_p_1): NULLPTR_TYPE types
	are equal.

	cp/
	* cp-tree.h (NULLPTR_TYPE_P): Adjust.
	* decl.c (cxx_init_decl_processing): Build a NULLPTR_TYPE node,
	use build_int_cst.
	* error.c (dump_type): Handle NULLPTR_TYPE.
	(dump_type_prefix): Likewise.
	(dump_type_suffix): Likewise.
	* mangle.c (write_type): Likewise.
	* name-lookup.c (arg_assoc_type): Likewise.
	* rtti.c (typeinfo_in_lib_p): Likewise.
	* pt.c (tsubst): Likewise.

	* g++.dg/lto/20101010-3_0.C: New testcase.
	* g++.dg/lto/20101010-4_0.C: Likewise.

From-SVN: r165462
2010-10-14 11:59:47 +00:00
Iain Sandoe
a16ced220f adjust recent tests for -fnext-runtime:
gcc/testsuite:

	* objc.dg/pr45878.m: Update to include NSConstantString interface
	for -fnext-runtime.
	* objc.dg/pr23214.m: Use the Object1.m implementation to build m64 on
	-fnext-runtime, XFAIL the m64 -fnext-runtime run.
	* objc.dg/objc-foreach-4.m: Provide an NSConstantString dummy class
	reference for m64 -fnext-runtime.

From-SVN: r165461
2010-10-14 10:40:07 +00:00
Joseph Myers
48476d13b2 params.c (params_finished): New.
* params.c (params_finished): New.
	(add_params): Assert !params_finished.
	(finish_params): New.
	(set_param_value_internal): Take params and params_set
	parameters.  Assert params_finished.
	(set_param_value, maybe_set_param_value): Take params and
	params_set parameters.  Update calls to set_param_value_internal.
	(set_default_param_value): Assert !params_finished.  Don't use
	set_param_value_internal.
	(default_param_value, init_param_values): New.
	* params.h (struct param_info): Change value to default_value.
	Remove set.
	(set_param_value, maybe_set_param_value): Add params and
	params_set parameters.
	(PARAM_VALUE): Get parameters from global_options.
	(PARAM_SET_P): Remove.
	(finish_params, default_param_value, init_param_values): New.
	* common.opt (param_values): New Variable.
	* config/arm/arm.c (arm_option_override): Pass extra arguments to
	maybe_set_param_value.
	* config/i386/i386.c (ix86_option_override_internal): Pass extra
	arguments to maybe_set_param_value.
	* config/picochip/picochip.c (picochip_option_override): Pass
	extra arguments to maybe_set_param_value.
	* config/rs6000/rs6000.c (rs6000_option_override_internal): Pass
	extra arguments to maybe_set_param_value.
	* config/s390/s390.c (s390_option_override): Use
	maybe_set_param_value instead of set_param_value.  Pass extra
	arguments to maybe_set_param_value.
	* config/sparc/sparc.c (sparc_option_override): Pass extra
	arguments to maybe_set_param_value.
	* config/spu/spu.c (spu_option_override): Pass extra arguments to
	maybe_set_param_value.
	* opts.c (handle_param): Take opts and opts_set parameters.
	Update call to set_param_value.
	(initial_min_crossjump_insns,
	initial_max_fields_for_field_sensitive,
	initial_loop_invariant_max_bbs_in_loop): Remove.
	(init_options_once): Don't set them.
	(init_options_struct): Initialize parameters structures.
	(default_options_optimization): Use default_param_value when
	restoring defaults.  Update calls to maybe_set_param_value.
	(finish_options): Update calls to maybe_set_param_value.
	(common_handle_option): Update calls to handle_param and
	set_param_value.
	* toplev.c (DEFPARAM): Update definition for changes to
	param_info.
	(general_init): Call finish_params.

From-SVN: r165460
2010-10-14 11:22:43 +01:00
Nick Clifton
4af476d7f2 mn10300.h (CONSTANT_ALIGNMENT): Define.
* config/mn10300/mn10300.h (CONSTANT_ALIGNMENT): Define.
        (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
        (FIRST_PSEUDO_REGISTER): Increase by one.
        (FIXED_REGISTERS, CALL_USED_REGISTERS): Update with CC_REG.
        (HARD_REGNO_MODE_OK): Call mn10300_hard_regno_mode_ok.
        (MODES_TIEABLE): Call mn10300_modes_tieable.
        (REG_CLASS_NAMES, REG_CLASS_CONTENTS, REGNO_REG_CLASS): Add
        CC_REGS.
        (LEGITIMATE_CONSTANT_P): Call mn10300_legitimate_constant_p.
        (CC_OVERFLOW_UNUSABLE, CC_NO_CARRY, NOTICE_UPDATE_CC)
        (SELECT_CC_MODE, REVERSIBLE_CC_MODE): Delete.
        (REGISTER_NAMES, ADDITIONAL_REGISTER_NAMES): Add CC register.
        (ASM_OUTPUT_REG_PUSH, ASM_OUTPUT_REG_POP): Delete.
        (mn10300_cc_status_mdep): Delete.
        (CC_STATUS_MDEP, CC_STATUS_MDEP_INIT): Delete.
        * config/mn10300/mn10300 (mn10300_option_override): Stop disabling
        the combine-stack-adjust pass.
        (print_operand): Use the mode of the comparison operation to
        select the comparison suffix.
        (notice_update_cc): Delete.
        (mn10300_secondary_reload_class): Remove test for stack pointer
        based arithmetic.
        (output_tst): Rename to mn10300_output_cmp.
        (impossible_plus_operand): Move into predicates.md.
        (mn10300_legitimize_address): Make static.
        (mn10300_legitimate_address_p): Make static.  Only allow SI sized
        constant pic operands.
        (mn10300_legitimate_constant_p): New function.
        (mn10300_case_values_threshold): Make static.
        (mn10300_hard_regno_mode_ok): New function.
        (mn10300_modes_tieable): New function.
        (mn10300_select_cc_mode): New function.
        * config/mn10300/predicates.md (impossible_plus_operand): Define.
        * config/mn10300/mn10300-protos.h: Tidy.
        (mn10300_legitimate_constant_p, mn10300_modes_tieable)
        (mn10300_hard_regno_mode_ok, mn10300_select_cc_mode): Prototype.
        * config/mn10300/mn10300.md (cc attribute): Delete.  Replace
        with clobbers or sets of CC_REG.
        (CC_REG): Define.
        (mov*): Remove use of CLR instruction.
        (cbranch_si4_<code>): New pattern/split.
        (integer_conditional_branch): New pattern.
        (cbranch_sf4_<code>): New pattern/split.
        (float_conditional_branch): New pattern.
        (casesi): Use addsi3 pattern instead of movsi pattern to add and
        move a value at the same time.
        (cc0 peepholes): Remove.

From-SVN: r165459
2010-10-14 09:12:50 +00:00
H.J. Lu
6203e21acb Add another 256bit vectorizer test.
2010-10-14  H.J. Lu  <hongjiu.lu@intel.com>

	* gcc.target/i386/vect-sizes-1.c: New.

From-SVN: r165458
2010-10-14 01:49:27 -07:00
H.J. Lu
4efeac88ee Scan 256bit AVX register and xfail vectorize4-avx.c.
2010-10-14  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/46011
	* gcc.target/i386/vectorize4-avx.c: Scan 256bit AVX register
	and xfail.

From-SVN: r165457
2010-10-14 01:33:09 -07:00
H.J. Lu
c7a9c0e337 Scan 256bit AVX register.
2010-10-14  H.J. Lu  <hongjiu.lu@intel.com>

	* gcc.target/i386/recip-vec-sqrtf-avx.c: Scan 256bit AVX
	register.
	* gcc.target/i386/recip-vec-divf-avx.c: Likewise.

From-SVN: r165456
2010-10-14 01:19:32 -07:00
Andrey Belevantsev
cfeb0fa8c9 sel-sched-ir.c (init_global_and_expr_for_insn): Set CANT_MOVE on RTX_FRAME_RELATED_P insns and the insn to which...
* sel-sched-ir.c (init_global_and_expr_for_insn): Set CANT_MOVE on RTX_FRAME_RELATED_P
    insns and the insn to which NOTE_INSN_EPILOGUE_BEG is attached.
    * sched-vis.c (print_value): Allow NULL value.

    * gcc.target/ia64/20101005.c: New test.

From-SVN: r165455
2010-10-14 11:59:57 +04:00
Andrey Belevantsev
3e6a3f6fc3 re PR rtl-optimization/45570 (ICE: in cfg_preds_1, at sel-sched-ir.c:4584)
PR rtl-optimization/45570
	* sel-sched-ir.c (cfg_preds_1): When walking out of the region, assert
	that we are pipelining outer loops.  Allow returning zero predecessors.
	* gcc.dg/pr45570.c: New test.

From-SVN: r165454
2010-10-14 11:56:47 +04:00
Andrey Belevantsev
262d82326e sel-sched-ir.c (maybe_tidy_empty_bb): Simplify comment.
* sel-sched-ir.c (maybe_tidy_empty_bb): Simplify comment.
        (tidy_control_flow): Tidy vertical space.
        (sel_remove_bb): New variable idx.  Use it to remember the basic
        block index before deleting the block.
        (sel_remove_empty_bb): Remove dead code, simplify and insert to ...
        (sel_merge_blocks): ... here.
        * sel-sched-ir.h (sel_remove_empty_bb): Remove prototype.

From-SVN: r165453
2010-10-14 11:39:07 +04:00
Jakub Jelinek
6699b754e1 cse.c (is_dead_reg): Change into inline function that is not called through for_each_rtx.
* cse.c (is_dead_reg): Change into inline function that is not
	called through for_each_rtx.
	(set_live_p): Adjust caller.
	(insn_live_p): Don't reset DEBUG_INSNs here.
	(struct dead_debug_insn_data): New data. 
	(count_stores, is_dead_debug_insn, replace_dead_reg): New functions.
	(delete_trivially_dead_insns): If there is just one setter for the
	dead reg that is referenced by some DEBUG_INSNs, create a DEBUG_EXPR
	and add DEBUG_INSN for it right before the removed setter and
	use the DEBUG_EXPR instead of the dead pseudo.

From-SVN: r165452
2010-10-14 09:17:54 +02:00
Zdenek Dvorak
d2e60b7bc2 et-forest.c (et_nca): Return NULL immediately when the dominance forest has disjoint components.
2010-10-14  Zdenek Dvorak  <rakdver@kam.uniff.cz>
        * et-forest.c (et_nca): Return NULL immediately when
        the dominance forest has disjoint components.

From-SVN: r165451
2010-10-14 11:08:45 +04:00
Vladimir Makarov
854edfcda4 ira.c (setup_class_hard_regs): Fix typo in indexing ira_non_ordered_class_hard_regs and ira_class_hard_reg_index.
2010-10-13  Vladimir Makarov  <vmakarov@redhat.com>

	* ira.c (setup_class_hard_regs): Fix typo in indexing
	ira_non_ordered_class_hard_regs and ira_class_hard_reg_index.

From-SVN: r165450
2010-10-14 03:07:59 +00:00
H.J. Lu
0d16f46289 Add more 256bit AVX testcases.
2010-10-13  H.J. Lu  <hongjiu.lu@intel.com>

	* gcc.target/i386/recip-vec-sqrtf-avx.c: New.
	* gcc.target/i386/recip-vec-divf-avx.c: Likewise.
	* gcc.target/i386/vectorize4-avx.c: Likewise.

From-SVN: r165449
2010-10-13 19:42:50 -07:00
H.J. Lu
7f82d2aef8 Add testcases for 256bit AVX copysign.
2010-10-13  H.J. Lu  <hongjiu.lu@intel.com>

	* gcc.target/i386/avx-copysign-vec.c: New.
	* gcc.target/i386/avx-copysignf-vec.c: Likewise.

From-SVN: r165448
2010-10-13 19:36:41 -07:00
H.J. Lu
647030dcf2 Add a testcase for PR middle-end/44130.
2010-10-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/44130
	* gcc.target/i386/pr44130.c: New.

From-SVN: r165447
2010-10-13 19:27:59 -07:00
H.J. Lu
0f0dda2091 Add a testcase for PR middle-end/44144.
2010-10-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR middle-end/44144
	* gcc.target/i386/pr44144.c: New.

From-SVN: r165446
2010-10-13 19:22:09 -07:00
H.J. Lu
1f561f9ba4 Add a testcase for PR target/44180.
2010-10-13  H.J. Lu  <hongjiu.lu@intel.com>

	PR target/44180
	* gcc.target/i386/pr44180.c: New.

From-SVN: r165445
2010-10-13 19:11:59 -07:00
Tijs Wiebe Lefering
208d8b55ac F^C the vcg dump bug.
From-SVN: r165444
2010-10-14 01:48:43 +00:00
Jason Merrill
8943989dda re PR c++/45984 (ICE: canonical types differ for identical types)
PR c++/45984
	* class.c (fixup_attribute_variants): New fn.
	* cp-tree.h: Declare it.
	* pt.c (instantiate_class_template): Call it.
	* semantics.c (begin_class_definition): Call it.

From-SVN: r165443
2010-10-13 20:50:26 -04:00
GCC Administrator
b477c9658b Daily bump.
From-SVN: r165442
2010-10-14 00:17:36 +00:00
Jonathan Wakely
405de314b8 re PR libstdc++/45990 (28_regex/07_traits/char/isctype.cc XPASSes on Solaris 2/IRIX 6)
PR libstdc++/45990
	* include/bits/regex.h (regex_traits::isctype): DR 1337.

From-SVN: r165438
2010-10-13 23:52:25 +01:00
Eric Botcazou
8908df28a6 re PR rtl-optimization/45912 (Patch for PR tree-optimization/44972 caused 2500+ FAILs on Solaris 2/SPARC)
PR rtl-optimization/45912
	* ira-costs.c (ira_tune_allocno_costs_and_cover_classes): Test the
	regno of registers instead of their index to compute the alignment.

From-SVN: r165437
2010-10-13 21:43:42 +00:00
H.J. Lu
1e27129f2e Addd 256bit AVX vectorizer patterns.
2010-10-13  H.J. Lu  <hongjiu.lu@intel.com>

	* config/i386/i386.c (ix86_build_const_vector): Check vector
	mode instead of scalar mode.
	(ix86_build_signbit_mask): Likewise.
	(ix86_expand_fp_absneg_operator): Updated.
	(ix86_expand_copysign): Likewise.
	(ix86_expand_int_vcond): Likewise.
	(ix86_emit_swdivsf): Likewise.
	(ix86_sse_copysign_to_positive): Likewise.
	(ix86_expand_sse_fabs): Likewise.
	* config/i386/i386.md (fixuns_trunc<mode>si2): Likewise.
	* config/i386/sse.md (copysign<mode>3): Likewise.
	(sse2_cvtudq2ps): Likewise.
	(vec_unpacku_float_hi_v4si): Likewise.
	(vec_unpacku_float_lo_v4si): Likewise.

	* config/i386/i386.c (ix86_builtins): Add
	IX86_BUILTIN_CPYSGNPS256 and IX86_BUILTIN_CPYSGNPD256.
	(bdesc_args): Likewise.
	(ix86_builtin_vectorized_function): Support 
	IX86_BUILTIN_CPYSGNPS256, IX86_BUILTIN_CPYSGNPD256,
	IX86_BUILTIN_SQRTPD256, IX86_BUILTIN_SQRTPS_NR256,
	and IX86_BUILTIN_CVTPS2DQ256.
	(ix86_builtin_reciprocal): Support IX86_BUILTIN_SQRTPS_NR256.

	* config/i386/sse.md (STORENT_MODE): New.
	(VEC_FLOAT_MODE): Likewise.
	(VEC_EXTRACT_MODE): Likewise.
	(*avx_cvtdq2pd256_2): Likewise.
	(vec_pack_trunc_v4df): Likewise.
	(vec_interleave_highv8sf): Likewise.
	(vec_interleave_lowv8sf): Likewise.
	(storent<mode>): Macroized.
	(<code><mode>2: absneg): Likewise.
	(copysign<mode>3): Likewise.
	(vec_extract<mode>): Likewise.

	PR target/44180
	* config/i386/i386.c (expand_vec_perm_even_odd_1): Rewritten
	for V8SFmode.

2010-10-13  Richard Guenther  <rguenther@suse.de>
	    H.J. Lu  <hongjiu.lu@intel.com>

	* config/i386/sse.md (reduc_splus_v8sf): Add.
	(reduc_splus_v4df): Likewise.
	(vec_unpacks_hi_v8sf): Likewise.
	(vec_unpacks_lo_v8sf): Likewise.
	(*avx_cvtps2pd256_2): Likewise.
	(vec_unpacks_float_hi_v8si): Likewise.
	(vec_unpacks_float_lo_v8si): Likewise.
	(vec_interleave_highv4df): Likewise.
	(vec_interleave_lowv4df): Likewise.

From-SVN: r165436
2010-10-13 14:20:07 -07:00
Richard Guenther
0d8485e009 re PR objc/45878 (Can't compile even a trivial ObjC program with -fexceptions -O2)
2010-10-13  Richard Guenther  <rguenther@suse.de>

	PR objc/45878
	* gimple-fold.c (gimple_fold_obj_type_ref): Leave OBJ_TYPE_REFs
	alone if there are no virtual methods.

	* objc.dg/pr45878.m: New testcase.

From-SVN: r165435
2010-10-13 20:30:10 +00:00
Richard Henderson
bde8a146a6 Centralize knowledge of eh personality routines.
From-SVN: r165433
2010-10-13 11:57:31 -07:00
Kai Tietz
d1655e0b38 dfp-scanf-1.c: Disable for *-*-mingw* targets.
2010-10-13  Kai Tietz  <kai.tietz@onevision.com>

        * gcc.dg/format/dfp-scanf-1.c: Disable for *-*-mingw* targets.
        * gcc.dg/format/dfp-printf-1.c: Likewise.
        * gcc.dg/format/ms_unnamed-1.c: Adjust linenumber for warning.

From-SVN: r165432
2010-10-13 20:39:57 +02:00
Richard Guenther
74e80a2473 re PR objc/45878 (Can't compile even a trivial ObjC program with -fexceptions -O2)
2010-10-13  Richard Guenther  <rguenther@suse.de>

	PR objc/45878
	* tree-ssa-ccpc (ccp_fold_stmt): Use gimple_fold_obj_type_ref.

From-SVN: r165430
2010-10-13 18:25:08 +00:00
Eric Botcazou
b1ba284ce3 cse.c (cse_insn): Fix thinko in the canonicalization of USE insns.
* cse.c (cse_insn): Fix thinko in the canonicalization of USE insns.
	Canonicalize input operands of ASM_OPERANDS insns.

From-SVN: r165429
2010-10-13 18:18:36 +00:00
Paolo Carlini
879b9073c8 random.h (discrete_distribution<>::param_type:: param_type()): Default construct the vectors.
2010-10-13  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/random.h (discrete_distribution<>::param_type::
	param_type()): Default construct the vectors.
	(discrete_distribution<>::param_type::probabilities): Adjust.
	(discrete_distribution<>::probabilities): Likewise.
	(discrete_distribution<>::max): Likewise.
	(piecewise_constant_distribution<>::param_type::
	param_type()): Default construct the vectors.
	(piecewise_constant_distribution<>::param_type::intervals): Adjust.
	(piecewise_constant_distribution<>::param_type::densities): Likewise.
	(piecewise_constant_distribution<>::intervals): Likewise.
	(piecewise_constant_distribution<>::densities): Likewise.
	(piecewise_constant_distribution<>::min): Likewise.
	(piecewise_constant_distribution<>::max): Likewise.
	(piecewise_linear_distribution<>::param_type::
	param_type()): Default construct the vectors.
	(piecewise_linear_distribution<>::param_type::intervals): Adjust.
	(piecewise_linear_distribution<>::param_type::densities): Likewise.
	(piecewise_linear_distribution<>::intervals): Likewise.
	(piecewise_linear_distribution<>::densities): Likewise.
	(piecewise_linear_distribution<>::min): Likewise.
	(piecewise_linear_distribution<>::max): Likewise.
	* include/bits/random.tcc (discrete_distribution<>::param_type::
	_M_initialize): Deal quickly with raw _M_prob equivalent to
	a default constructed param_type, just clear the vector.
	(discrete_distribution<>::operator()): Early return 0 for a
	default constructed distribution.
	(piecewise_constant_distribution<>::param_type::_M_initialize):
	Likewise for _M_int and _M_den.
	(piecewise_constant_distribution<>::operator()): Early return
	for a default constructed distribution.
	(piecewise_linear_distribution<>::param_type::_M_initialize):
	Likewise.
	(piecewise_linear_distribution<>::operator()): Early return
	for a default constructed distribution.
	* testsuite/26_numerics/random/discrete_distribution/operators/
	call-default.cc: New.
	* testsuite/26_numerics/random/piecewise_constant_distribution/
	operators/call-default.cc: Likewise.

From-SVN: r165427
2010-10-13 16:31:17 +00:00
Xinliang David Li
18aebb0e6f Fix change log
From-SVN: r165426
2010-10-13 16:04:09 +00:00
Richard Guenther
1b7d2dd1e0 re PR tree-optimization/45788 (-fwhole-program causes ICE error: BB 3 can not throw but has an EH edge)
2010-10-13  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/45788
	* cgraphunit.c (cgraph_redirect_edge_call_stmt_to_callee): Delay
	EH update until fixup-cfg.

	* g++.dg/pr45788.C: New testcase.

From-SVN: r165425
2010-10-13 15:42:46 +00:00
Julian Brown
565d018dae arm.h (REG_CLASS_CONTENTS): Remove soft frame pointer from CORE_REGS and GENERAL_REGS classes.
gcc/
	* config/arm/arm.h (REG_CLASS_CONTENTS): Remove soft frame pointer
	from CORE_REGS and GENERAL_REGS classes.
	* config/arm/arm.md (*thumb1_movsi_insn): Ignore all parts of
	final constraint for register preferencing.

From-SVN: r165424
2010-10-13 14:22:07 +00:00
Richard Guenther
71d6134802 re PR tree-optimization/45970 (tree DSE misses many obvious dead stores)
2010-10-13  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/45970
	* tree-ssa-alias.h (stmt_kills_ref_p): Declare.
	* tree-ssa-alias.c (stmt_kills_ref_p_1): New function.
	(stmt_kills_ref_p): Likewise.
	* tree-ssa-dse.c (dse_optimize_stmt): Use it.

	* gcc.dg/tree-ssa/ssa-dse-13.c: New testcase.

From-SVN: r165422
2010-10-13 13:03:31 +00:00
Joseph Myers
9827eb57a3 * vi.po: Update.
From-SVN: r165420
2010-10-13 14:03:08 +01:00
Richard Guenther
cb89b4b090 re PR tree-optimization/45982 (PTA does not track integers)
2010-10-13  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/45982
	* tree-ssa-structalias.c (make_constraints_to): New function.
	(make_constraint_to): Implement in terms of make_constraints_to.
	(find_func_aliases): Properly make return values of pure/const
	functions escape if they assign to sth that is not a pointer.

	* gcc.dg/torture/pr45982.c: New testcase.
	* gcc.dg/tree-ssa/pr24287.c: Adjust.
	* gcc.dg/tree-ssa/pta-callused.c: Likewise.
	* gcc.dg/torture/pr39074-2.c: Likewise.

From-SVN: r165418
2010-10-13 11:31:22 +00:00
Richard Guenther
72351fa31f re PR middle-end/45874 (ICE in verify_flow_info failed)
2010-10-13  Richard Guenther  <rguenther@suse.de>

	PR middle-end/45874
	* cgraphunit.c (cgraph_redirect_edge_call_stmt_to_callee):
	Fixup the CFG when EH was fixed up.

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

From-SVN: r165416
2010-10-13 10:06:28 +00:00
Iain Sandoe
a1178b309a implement method attributes.
gcc/c-family:
	merge from FSF apple 'trunk' branch. 
	2006-04-26 Fariborz Jahanian <fjahanian@apple.com>

	Radar 3803157 (method attributes)
	* c-common.c (handle_deprecated_attribute): Recognize
	objc methods as valid declarations.
	* c-common.h: Declare objc_method_decl ().
	* stub-objc.c (objc_method_decl): New stub. 

gcc/objc:
	merge from FSF apple 'trunk' branch. 

	2006-04-26 Fariborz Jahanian <fjahanian@apple.com>
	Radar 3803157 (method attributes)
	* objc/objc-act.h (METHOD_TYPE_ATTRIBUTES): New macro.
	* objc/objc-act.c (objc_decl_method_attributes): New.
	(objc_add_method_declaration): Process method's attribute.
	(objc_start_method_definition): Ditto.
	(build_objc_method_call): Inject method attribute into
	built function type.
	(objc_method_decl): New.
	(objc_warn_deprecated)use): New.

testsuite:
	* objc.dg/attributes/method-attribute-1.m: Update to respond
	to implemented method attributes..
	* objc.dg/attributes/method-attribute-2.m: Likewise.
	* objc.dg/attributes/method-attribute-3.m: Likewise.
	* obj-c++.dg/attributes/method-attribute-1.mm: Likewise.
	* obj-c++.dg/attributes/method-attribute-2.mm: Likewise.
	* obj-c++.dg/attributes/method-attribute-3.mm: Likewise.

From-SVN: r165415
2010-10-13 08:24:48 +00:00
Nicola Pero
5254c66ba0 In libobjc/: 2010-10-13 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-13  Nicola Pero  <nicola.pero@meta-innovation.com>

        PR libobjc/23214
        * init.c (objc_init_statics): Do not skip the initialization of a
        statics list if the first object has already been initialized; in
        the case of Protocols, while the first one may have been
        initialized, some others may not have been initialized yet.

In gcc/testsuite/:
2010-10-13  Nicola Pero  <nicola.pero@meta-innovation.com>

        PR libobjc/23214
        * objc.dg/pr23214.m: New.

From-SVN: r165414
2010-10-13 08:16:42 +00:00
Richard Guenther
b4ca4f9e32 tree.c (cp_free_lang_data): Free DECL_NAMESPACE_USERS and clear DECL_CHAIN of NAMESPACE_DECLs.
2010-10-12  Richard Guenther  <rguenther@suse.de>

	* tree.c (cp_free_lang_data): Free DECL_NAMESPACE_USERS and
	clear DECL_CHAIN of NAMESPACE_DECLs.

From-SVN: r165413
2010-10-13 08:15:47 +00:00
Ira Rosen
d59dc888de tree-vect-slp.c (vect_get_constant_vectors): Fix comment.
* tree-vect-slp.c (vect_get_constant_vectors): Fix comment.
	Use operand's type for POINTER_PLUS_EXPR.

From-SVN: r165412
2010-10-13 07:43:10 +00:00
Alexandre Oliva
3f6d4c520c * c-parser.c (c_parser_for_statement): Initialize incr.
From-SVN: r165411
2010-10-13 05:21:52 +00:00
Michael Eager
187e3629ab re PR testsuite/45856 (gcc.c-torture/execute/cmpsf-1.c/cmpsi-2.c failed on x86-64)
PR 45856

From-SVN: r165410
2010-10-13 02:27:42 +00:00
Nicola Pero
b0453850df In libobjc/: 2010-10-13 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-13  Nicola Pero  <nicola.pero@meta-innovation.com>

        * Makefile.in (OBJC_DEPRECATED_H): Added
        objc_get_uninstalled_dtable, objc_object_alloc.h and
        struct_objc_static_instances.h.

From-SVN: r165409
2010-10-13 01:08:43 +00:00
GCC Administrator
a9c5e72061 Daily bump.
From-SVN: r165408
2010-10-13 00:18:59 +00:00
Nicola Pero
ad49efbd54 In libobjc/: 2010-10-13 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-13  Nicola Pero  <nicola.pero@meta-innovation.com>

        * encoding.c (method_copyReturnType): New.
        (method_copyArgumentType): New.
        (method_getReturnType): New.
        (method_getArgumentType): New.
        * methods.c (method_getDescription): New.
        * objc/runtime.h (method_copyReturnType): New.
        (method_copyArgumentType): New.
        (method_getReturnType): New.
        (method_getArgumentType): New.
        (method_getDescription): New.

From-SVN: r165404
2010-10-13 00:15:43 +00:00
Nicola Pero
c994cc85bd In libobjc/: 2010-10-12 Nicola Pero <nicola.pero@meta-innovation.com>
In libobjc/:
2010-10-12  Nicola Pero  <nicola.pero@meta-innovation.com>

        * encoding.c: Tidied up comments.
        (objc_skip_variable_name): New static inline function.
        (objc_sizeof_type): Use objc_skip_variable_name instead of copying
        the same code over and over.
        (objc_alignof_type): Same.
        (objc_aligned_size): Same.
        (objc_promoted_size): Same.
        (objc_skip_typespec): Same.
        (objc_layout_structure_next_member): Same.
        (objc_skip_offset): Skip a '-' before the digits (if any).  Fixed
        historical bug where objc_skip_offset would skip one byte even if
        there is no offset: check that the first offset digit is actually
        a digit before skipping it.
        (objc_skip_type_qualifiers): Mark as inline.
        (objc_skip_typespec): Mark as inline.

From-SVN: r165403
2010-10-12 22:57:57 +00:00
Xinliang David Li
98d30e4fb5 fix pr/45972
From-SVN: r165402
2010-10-12 22:32:00 +00:00
Jakub Jelinek
f468424220 re PR fortran/45636 (Failed to fold simple Fortran string)
PR fortran/45636
	* tree-ssa-forwprop.c: Include expr.h.
	(constant_pointer_difference, simplify_builtin_call): New functions.
	(tree_ssa_forward_propagate_single_use_vars): Call
	simplify_builtin_call on builtin calls.

	* gcc.c-torture/execute/pr45636.c: New test.
	* gfortran.dg/pr45636.f90: New test.

From-SVN: r165401
2010-10-13 00:01:04 +02:00