Commit Graph

108890 Commits

Author SHA1 Message Date
Richard Guenther e834e95c36 re PR lto/48978 (excessive hash table allocation for large lto build)
2011-05-13  Richard Guenther  <rguenther@suse.de>

	PR lto/48978
	* gimple.c (iterative_hash_gimple_type): Revert change in
	pointer target and function result and argument hashing.

From-SVN: r173730
2011-05-13 11:02:28 +00:00
Uros Bizjak 3420348330 i386.md (*movxf_internal): Use !can_create_pseudo ().
* config/i386/i386.md (*movxf_internal): Use !can_create_pseudo ().
	(*movxf_internal_nointeger): Ditto.
	(*movdf_internal_rex64): Ditto.
	(*movdf_internal): Ditto.
	(*movdf_internal_nointeger): Ditto.
	(*movsf_internal): Ditto.
	(sincos splitters): Use can_create_pseudo ().

From-SVN: r173729
2011-05-13 12:16:43 +02:00
Joseph Myers 7eb68c06bc i386-opts.h: New.
* config/i386/i386-opts.h: New.
	* gcc/config/i386/i386.c (stringop_alg, ix86_cmodel,
	ix86_asm_dialect, ix86_regparm, ix86_abi, ix86_branch_cost,
	ix86_section_threshold): Remove.
	(ix86_handle_option): Move MAX_CODE_ALIGN define here.  Handle
	OPT_malign_loops_, OPT_malign_jumps_, OPT_malign_functions_ and
	OPT_mbranch_cost_.
	(ix86_option_override_internal): Don't decode strings for options
	other than -march=, -mtune= and -mfpmath=.  Don't allow for
	__attribute__ uses in remaining diagnostics for options with
	string arguments.  Don't check for integer arguments being
	negative.
	* gcc/config/i386/i386.h (enum stringop_alg, enum calling_abi,
	enum tls_dialect, enum cmodel, enum asm_dialect): Move to
	i386-opts.h.
	(ix86_abi, ix86_tls_dialect, ix86_cmodel, ix86_asm_dialect,
	ix86_branch_cost, ix86_section_threshold): Remove.
	* gcc/config/i386/i386.opt (config/i386/i386-opts.h): New
	HeaderInclude.
	(malign-functions=, malign-jumps=, malign-loops=): Use UInteger
	but not Var.
	(masm=): Use Enum and Init.
	(asm_dialect): New Enum and EnumValue entries.
	(mbranch-cost=): Use UInteger.
	(mlarge-data-threshold=): Use UInteger and Init.
	(mcmodel=): Use Enum and Init.
	(cmodel): New Enum and EnumValue entries.
	(mpc): Replace with separate mpc32, mpc64 and mpc80 entries.
	(mpreferred-stack-boundary=, mincoming-stack-boundary=,
	mregparm=): Use UInteger.
	(mstringop-strategy=): Use Enum and Init.
	(stringop_alg): New Enum and EnumValue entries.
	(mtls-dialect=): Use Enum and Init.
	(tls_dialect): New Enum and EnumValue entries.
	(mabi=): Use Enum and Init.
	(calling_abi): New Enum and EnumValue entries.
	(mveclibabi=): Use Enum and Init.
	(ix86_veclibabi): New Enum and EnumValue entries.

From-SVN: r173728
2011-05-13 10:59:13 +01:00
Nick Clifton f67e203c1f rx.md (mov expander): Fix use of rx_legitimate_constant_p.
* config/rx/rx.md (mov expander): Fix use of
	rx_legitimate_constant_p.
	* config/rx/rx-protos.h (rx_legitimate_constant_p): Rename
	prototype.

From-SVN: r173727
2011-05-13 09:35:28 +00:00
Kai Tietz 221df0b62d re PR middle-end/48984 (Many testsuite failures)
2011-05-13  Kai Tietz  <ktietz@redhat.com>

        PR middle-end/48984
        * gimplify.c (gimplify_expr): Check for boolean_type_node instead
        for BOOLEAN_TYPE for TRUTH-NOT/AND/OR/XOR.
        (gimple_boolify): Check for cast for boolean_type_node instead for
        BOOLEAN_TYPE.

From-SVN: r173726
2011-05-13 11:21:36 +02:00
Richard Guenther 208cb8cbad re PR tree-optimization/48172 (incorrect vectorization of loop in GCC 4.5.* with -O3)
2011-05-13  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/48172
	* tree-vect-loop-manip.c (vect_vfa_segment_size): Avoid
	multiplying by number of iterations for equal step.
	(vect_create_cond_for_alias_checks): Likewise.

From-SVN: r173725
2011-05-13 08:31:18 +00:00
Andreas Schwab b88ecf553e configure.ac: Use AS_HELP_STRING throughout.
* configure.ac: Use AS_HELP_STRING throughout.
* configure: Regenerate.

From-SVN: r173724
2011-05-13 08:09:25 +00:00
Toon Moene e6e9475b4b objc-next-runtime-abi-02.c (newabi_append_ro): Add const qualifier to constant variable pointer declaration.
2011-05-13  Toon Moene  <toon@moene.org>

	* objc-next-runtime-abi-02.c (newabi_append_ro):
	Add const qualifier to constant variable pointer declaration.

From-SVN: r173723
2011-05-13 07:47:42 +00:00
GCC Administrator a2eba9136c Daily bump.
From-SVN: r173722
2011-05-13 00:19:31 +00:00
H.J. Lu 569b527e6f Change maybe_eh_return to bool.
2011-05-12  H.J. Lu  <hongjiu.lu@intel.com>

	* config/i386/i386.c (ix86_save_reg): Change maybe_eh_return
	to bool.
	(ix86_emit_restore_regs_using_mov): Likewise.
	(ix86_emit_restore_sse_regs_using_mov): Likewise.

From-SVN: r173716
2011-05-12 14:36:48 -07:00
DJ Delorie d53903d64c Fix missing file name in changelog
From-SVN: r173715
2011-05-12 16:52:32 -04:00
Anatoly Sokolov 8b9a1428e5 sparc.h (REG_OK_FOR_INDEX_P, [...]): Remove.
* config/sparc/sparc.h (REG_OK_FOR_INDEX_P, REG_OK_FOR_BASE_P,
	SYMBOLIC_CONST, RTX_OK_FOR_BASE_P, RTX_OK_FOR_INDEX_P): Remove.
	(RTX_OK_FOR_OFFSET_P, RTX_OK_FOR_OLO10_P): Move to...
	* config/sparc/sparc.c (RTX_OK_FOR_OFFSET_P,
	RTX_OK_FOR_OLO10_P): ...here.
	(sparc_mode_dependent_address_p): Use symbolic_operand instead of
	SYMBOLIC_CONST.

From-SVN: r173714
2011-05-13 00:36:31 +04:00
Ian Lance Taylor acf9814605 Fix bug with taking address of a variable when address does not escape.
* go-gcc.cc (Gcc_backend::local_variable): Add is_address_taken
	parameter.
	(Gcc_backend::parameter_variable): Likewise.

From-SVN: r173712
2011-05-12 18:35:05 +00:00
Kai Tietz 1d15f620aa gimplify.c (gimple_boolify): Re-boolify expression arguments even if expression type is of kind BOOLEAN_TYPE.
2011-05-12  Kai Tietz  <ktietz@redhat.com>

	* gimplify.c (gimple_boolify): Re-boolify expression
	arguments even if expression type is of kind BOOLEAN_TYPE.
	(gimplify_boolean_expr): Removed.
	(gimplify_expr): Boolify truth opcodes AND, ANDIF, OR, ORIF,
	and XOR. Additional take care that we keep expression's type.
	* tree-cfg.c (verify_gimple_assign_binary): Adjust check for type
	of TRUTH_AND|OR|XOR_EXPR.

From-SVN: r173711
2011-05-12 20:19:07 +02:00
Jakub Jelinek c2b5fc8de6 re PR tree-optimization/48975 (ICE in execute_cse_reciprocals() with -fno-tree-slp-vectorize)
PR tree-optimization/48975
	* tree-if-conv.c (combine_blocks): Call free_bb_predicate
	on all bbs here and free and clear ifc_bbs at the end.

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

From-SVN: r173709
2011-05-12 19:44:23 +02:00
Tobias Burnus 13157033d4 re PR fortran/48972 (OPEN with Unicode file name)
2011-05-12  Tobias Burnus  <burnus@net-b.de>

        PR fortran/48972
        * resolve.c (resolve_intrinsic): Don't resolve module
        intrinsics multiple times.

2011-05-12  Tobias Burnus  <burnus@net-b.de>

        PR fortran/48972
        * gfortran.dg/iso_c_binding_compiler_3.f90: New.

From-SVN: r173708
2011-05-12 19:40:29 +02:00
Jason Merrill 16c20b0a55 cp-tree.h (DECL_DEFERRED_CONSTEXPR_CHECK): New.
* cp-tree.h (DECL_DEFERRED_CONSTEXPR_CHECK): New.
	* semantics.c (validate_constexpr_fundecl): Set it.
	(check_deferred_constexpr_decls): Clear it.
	(register_constexpr_fundef): Make sure it isn't set.
	* decl.c (grok_special_member_properties): Check it.

From-SVN: r173707
2011-05-12 13:33:53 -04:00
Eric Botcazou 7bf9a5ac1c trans.c (call_to_gnu): In the by-reference case...
* gcc-interface/trans.c (call_to_gnu): In the by-reference case, if the
	type of the parameter is an unconstrained array, convert the actual to
	the type of the formal in the In Out and Out cases as well.

From-SVN: r173706
2011-05-12 14:54:09 +00:00
Richard Guenther 61332f7774 gimple.c (gtc_visit): Compare TREE_ADDRESSABLE, handle NULLPTR_TYPE similar to VOID_TYPE.
2011-05-12  Richard Guenther  <rguenther@suse.de>

	* gimple.c (gtc_visit): Compare TREE_ADDRESSABLE, handle
	NULLPTR_TYPE similar to VOID_TYPE.  Defer type-leader lookup
	until after simple checks.
	(gimple_types_compatible_p): Likewise.
	(iterative_hash_gimple_type): Always hash pointer targets
	and function return and argument types.
	(iterative_hash_canonical_type): Do not hash TYPE_QUALS,
	hash TYPE_ALIGN.  Do not hash TYPE_MIN/MAX_VALUE.
	(gimple_canonical_types_compatible_p): Compare TREE_ADDRESSABLE,
	handle NULLPTR_TYPE similar to VOID_TYPE.  Handle non-aggregates
	completely in the simple compare section.
	(gimple_register_canonical_type): Query the cache again after
	registering.

From-SVN: r173704
2011-05-12 14:04:29 +00:00
Richard Guenther e2a3a5f1ad re PR tree-optimization/48172 (incorrect vectorization of loop in GCC 4.5.* with -O3)
2011-05-12  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/48172
	* tree-vect-loop-manip.c (vect_vfa_segment_size): Do not exclude
	the number of iterations from the segment size calculation.
	(vect_create_cond_for_alias_checks): Adjust.

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

From-SVN: r173703
2011-05-12 12:14:45 +00:00
Jakub Jelinek 2c703f3a6a re PR debug/48967 (ICE during use_narrower_mode)
PR debug/48967
	* var-tracking.c (use_narrower_mode_test) <case REG>: Return 1
	if validate_subreg fails.

	* g++.dg/opt/pr48967.C: New test.

From-SVN: r173701
2011-05-12 13:54:33 +02:00
Jan Hubicka 35d828c58b re PR lto/48952 (ICE in inline_merge_summary during linux kernel LTO build)
PR lto/48952
	* lto.c (do_whole_program_analysis): Do not register cgraph hooks.

From-SVN: r173700
2011-05-12 11:30:42 +00:00
Hariharan Sandanagobalane b27981e06b ira.c (clarify_prohibited_class_mode_regs): Prevent the function from accessing beyond the end of REGNO_REG_CLASS array by...
* ira.c (clarify_prohibited_class_mode_regs): Prevent the function from
          accessing beyond the end of REGNO_REG_CLASS array by stopping the
          loop early.

From-SVN: r173699
2011-05-12 11:12:12 +00:00
Joseph Myers f3b143f080 * zh_CN.po: Update.
From-SVN: r173697
2011-05-12 12:02:23 +01:00
DJ Delorie 87e91fca2d (rx_builtins): New arrays - holds builtin functions.
(ADD_RX_BUILTIN1, ADD_RX_BUILTIN2, ADD_RX_BUILTIN3): Install
	created builtin into rx_builtins array.
	(rx_builtin_decl): New function.
	(TARGET_BUITLIN_DECL): Define.
	Include gt-rx.h.

Co-Authored-By: Nick Clifton <nickc@redhat.com>

From-SVN: r173696
2011-05-12 10:33:57 +00:00
DJ Delorie 5f2f13fde2 rx.h (HAVE_PRE_DECREMENT): Fix typo.
* config/rx/rx.h (HAVE_PRE_DECREMENT): Fix typo.
	* config/rx/rx.c (CC_FLAG_FP): Fix comment.
	(rx_is_legitimate_address): Add pre-decrement and post-increment
	addressing in HImode and QImode.  Fix test for out of range
	REG+INT addressing.
	(rx_legitimate_constant_p): Rename ro rx_is_legitimate_constant.
	(rx_align_for_label): Test label before extracting its usage
	count.
	(rx_adjust_insn_lengths): Fix selection of insn codes.
	(TARGET_LEGITIMNATE_CONSTANT_P): Use renamed function.

Co-Authored-By: Nick Clifton <nickc@redhat.com>

From-SVN: r173695
2011-05-12 10:30:28 +00:00
Jason Merrill 57421f45e8 * tree.c (type_hash_canon): Use struct tree_type_non_common.
From-SVN: r173692
2011-05-11 21:36:38 -04:00
GCC Administrator 0ebc7af178 Daily bump.
From-SVN: r173691
2011-05-12 00:18:47 +00:00
Paul Pluzhnikov e77e2cbbee No gcc/ prefix in gcc/ChangeLog.
From-SVN: r173686
2011-05-11 16:15:44 -07:00
Eric Botcazou 898c90c0fd cfgrtl.c (commit_one_edge_insertion): Remove always-true test and reindent the subsequent block.
* cfgrtl.c (commit_one_edge_insertion): Remove always-true test and
	reindent the subsequent block.

From-SVN: r173685
2011-05-11 23:05:51 +00:00
Paolo Carlini cddebdb7a8 overloads_c++0x_neg.cc: Use dg-require-cmath.
2011-05-11  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/26_numerics/headers/cmath/overloads_c++0x_neg.cc: Use
	dg-require-cmath.
	* testsuite/tr1/8_c_compatibility/cmath/overloads_neg.cc: Likewise.

From-SVN: r173684
2011-05-11 22:36:18 +00:00
Jason Merrill 6eb47b9829 re PR c++/48948 ([C++0x] constexpr friend function cannot be defined in-class)
PR c++/48948
	* semantics.c (validate_constexpr_fundecl): Defer checking if
	an argument type is being defined.
	(is_valid_constexpr_fn): Add defer_ok parm.
	(cxx_eval_call_expression): Adjust.
	(check_deferred_constexpr_decls): New.
	(literal_type_p): Make sure type isn't being defined.
	(ensure_literal_type_for_constexpr_object): Handle type being defined.
	* cp-tree.h: Declare check_deferred_constexpr_decls.
	* decl.c (grokfndecl): Call validate_constexpr_fundecl here.
	(start_preparsed_function, cp_finish_decl): Not here.
	* class.c (finalize_literal_type_property): Don't call
	validate_constexpr_fundecl.
	(finish_struct): Call check_deferred_constexpr_decls.
	* pt.c (tsubst_decl): Call validate_constexpr_fundecl.
	(instantiate_class_template): Call check_deferred_constexpr_decls.

From-SVN: r173683
2011-05-11 17:30:18 -04:00
Jason Merrill 3c5283a738 semantics.c (validate_constexpr_fundecl): Check DECL_TEMPLATE_INFO rather than DECL_TEMPLATE_INSTANTIATION.
* semantics.c (validate_constexpr_fundecl): Check DECL_TEMPLATE_INFO
	rather than DECL_TEMPLATE_INSTANTIATION.
	(cxx_eval_call_expression): Likewise.

From-SVN: r173682
2011-05-11 17:30:10 -04:00
Jason Merrill 9b41f0d327 semantics.c (register_constexpr_fundef): Add to hash table here.
* semantics.c (register_constexpr_fundef): Add to hash table here.
	(validate_constexpr_fundecl): Not here.

From-SVN: r173681
2011-05-11 17:30:02 -04:00
Jason Merrill efd115c1c6 * decl.c (grokdeclarator): Only set DECL_DECLARED_CONSTEXPR_P once.
From-SVN: r173680
2011-05-11 17:29:56 -04:00
Jason Merrill f5ad54d778 pt.c (build_non_dependent_expr): Don't check null_ptr_cst_p, do call maybe_constant_value in C++0x mode.
* pt.c (build_non_dependent_expr): Don't check null_ptr_cst_p,
	do call maybe_constant_value in C++0x mode.
	* semantics.c (cxx_eval_constant_expression): Handle TEMPLATE_DECL.

From-SVN: r173679
2011-05-11 17:29:49 -04:00
Jason Merrill 3e475d30a3 re PR c++/48745 ([C++0x] Segmentation fault with list-initialization, void initializers and variadics)
PR c++/48745
	* pt.c (value_dependent_expr_p): Handle CONSTRUCTOR.

From-SVN: r173678
2011-05-11 17:29:35 -04:00
Tobias Burnus 0126595fee re PR fortran/48889 (f951: internal compiler error: in gfc_is_constant_expr, at fortran/expr.c:906)
2011-05-11  Tobias Burnus  <burnus@net-b.de>

        PR fortran/48889
        * expr.c (gfc_is_constant_expr): Use e->value.function.esym
        instead of e->symtree->n.sym, if available.

2011-05-11  Tobias Burnus  <burnus@net-b.de>

        PR fortran/48889
        * gfortran.dg/generic_24.f90: New.

From-SVN: r173674
2011-05-11 22:08:54 +02:00
Ian Lance Taylor 8da1c70b57 Permit new of a function type.
From-SVN: r173672
2011-05-11 19:56:39 +00:00
Ian Lance Taylor 2d8f63a164 Don't crash ranging over call to builtin function.
From-SVN: r173671
2011-05-11 19:39:21 +00:00
François Dumont cfca3f7267 hash_load_check_resize_trigger_imp.hpp (assert_valid): Replace _GLIBCXX_DEBUG_ASSERT calls with PB_DS_DEBUG_VERIFY.
2011-05-11  François Dumont  <francois.cppdevs@free.fr>

        * include/ext/pb_ds/detail/resize_policy/
        hash_load_check_resize_trigger_imp.hpp (assert_valid): Replace
        _GLIBCXX_DEBUG_ASSERT calls with PB_DS_DEBUG_VERIFY.
        * include/ext/pb_ds/detail/binomial_heap_base_/erase_fn_imps.hpp,
        find_fn_imps.hpp, insert_fn_imps.hpp, binomial_heap_base_.hpp,
        constructors_destructor_fn_imps.hpp, split_join_fn_imps.hpp
        (PB_DS_ASSERT_VALID): Rename in PB_DS_ASSERT_VALID_COND.
        * include/ext/pb_ds/detail/debug_map_base.hpp,
        splay_tree_/splay_tree_.hpp, ov_tree_map_/ov_tree_map_.hpp,
        cc_hash_table_map_/cc_ht_map_.hpp, pat_trie_/pat_trie_.hpp,
        leaf.hpp, internal_node.hpp, gp_hash_table_map_/gp_ht_map_.hpp,
        bin_search_tree_/bin_search_tree_.hpp, list_update_map_/lu_map_.hpp,
        rb_tree_map_/rb_tree_.hpp (PB_DS_ASSERT_VALID, PB_DS_DEBUG_VERIFY,
        PB_DS_CHECK_KEY_EXISTS, PB_DS_CHECK_KEY_DOES_NOT_EXIST): Duplicate
        macro definitions move...
        * include/ext/pb_ds/detail/container_base_dispatch.hpp: ... here...
        * include/ext/pb_ds/detail/basic_tree_policy/traits.hpp: ... and here.
        * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp,
        resize_policy.hpp, pairing_heap_/pairing_heap_.hpp,
        left_child_next_sibling_heap_/left_child_next_sibling_heap_.hpp,
        binomial_heap_/binomial_heap_.hpp, thin_heap_/thin_heap_.hpp,
        rc_binomial_heap_/rc_binomial_heap_.hpp, rc.hpp (PB_DS_ASSERT_VALID,
        PB_DS_DEBUG_VERIFY): Duplicate macro definitions move...
        * include/ext/pb_ds/detail/priority_queue_base_dispatch.hpp:
        ...here.

From-SVN: r173670
2011-05-11 19:29:02 +00:00
Paul Pluzhnikov 6e91d9d6b3 MAINTAINERS (Write After Approval): Add myself.
2011-05-11  Paul Pluzhnikov  <ppluzhnikov@google.com>

	* MAINTAINERS (Write After Approval): Add myself.

From-SVN: r173669
2011-05-11 11:43:43 -07:00
Satoru Takabayashi 79bec9233c install.texi (Configuration): Document --with-linker-hash-style.
2011-05-11  Satoru Takabayashi  <satorux@google.com>
	    Paul Pluzhnikov  <ppluzhnikov@google.com>

	* gcc/doc/install.texi (Configuration): Document
	--with-linker-hash-style.
	* gcc/gcc.c (init_spec): Handle LINKER_HASH_STYLE.
	* gcc/config.in: Add LINKER_HASH_STYLE.
	* gcc/configure.ac: Add --with-linker-hash-style.
	* gcc/configure: Regenerate.


Co-Authored-By: Paul Pluzhnikov <ppluzhnikov@google.com>

From-SVN: r173668
2011-05-11 11:28:14 -07:00
Nathan Froyd e5b00edff5 don't use build_function_type in the Ada FE
don't use build_function_type in the Ada FE
	* gcc-interface/utils.c (def_fn_type): Don't call build_function_type;
	call build_function_type_array or build_varargs_function_type_array
	instead.
	(create_subprog_type): Don't call build_function_type; call
	build_function_type_vec instead.

From-SVN: r173664
2011-05-11 15:53:50 +00:00
Richard Guenther d034095964 re PR bootstrap/48964 (LTO profiledbootstrap failure)
2011-05-11  Richard Guenther  <rguenther@suse.de>

	PR middle-end/48964
	* gimple.c (iterative_hash_canonical_type): Fix typo.

From-SVN: r173663
2011-05-11 15:44:59 +00:00
Uros Bizjak cb032feee8 i386.c (legitimize_tls_address): Call gen_tls_dynamic_gnu2_{32,64} expanders directly for TARGET_GNU2_TLS.
* config/i386/i386.c (legitimize_tls_address)
	<TLS_MODEL_GLOBAL_DYNAMIC>: Call gen_tls_dynamic_gnu2_{32,64}
	expanders directly for TARGET_GNU2_TLS.  Determine pic and
	__tls_get_addr symbol reference here.  Update call to
	gen_tls_global_dynamic_{32,64} for added arguments.
	<TLS_MODEL_LOCAL_DYNAMIC>: Call gen_tls_dynamic_gnu2_{32,64}
	expanders directly for TARGET_GNU2_TLS.  Determine
	__tls_get_addr symbol reference here.  Update call to
	gen_tls_local_dynamic_base_{32,64} for added arguments.  Attach
	unique UNSPEC REG_EQUIV to libcall block.
	(ix86_tls_get_addr): Declare static.
	* config/i386/i386-protos.h (ix86_tls_get_addr): Remove declaration.
	* config/i386/i386.md (tls_global_dynamic_32): Add operand 2 and 3.
	Do not determine pic and __tls_get_addr symbol reference here. Do not
	call gen_tls_dynamic_gnu2_32 for TARGET_GNU2_TLS.
	(tls_local_dynamic_base_32): Ditto for operands 1 and 2.
	(tls_global_dynamic_64): Add operand 2.  Do not determine
	__tls_get_addr symbol reference here.  Do not call
	gen_tls_dynamic_gnu2_64 for TARGET_GNU2_TLS here.
	(tls_local_dynamic_base64): Ditto for operand 1.

From-SVN: r173662
2011-05-11 17:30:52 +02:00
Eric Botcazou 6d3cc8f051 function.c (expand_function_start): Initialize stack_check_probe_note only if the generic stack checking mechanism...
* function.c (expand_function_start): Initialize stack_check_probe_note
	only if the generic stack checking mechanism is used.

From-SVN: r173661
2011-05-11 15:15:26 +00:00
Richard Guenther 51e020fc08 re PR tree-optimization/15256 ([tree-ssa] Optimize manual bitfield manipilation.)
2011-05-11  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/15256
	* tree-ssa-forwprop.c (simplify_bitwise_binary): Canonicalize
	(A & B) | C, combine (A op CST1) op CST2.
	(tree_ssa_forward_propagate_single_use_vars): Only bother to
	visit assigns that have uses.

	* gcc.dg/tree-ssa/forwprop-14.c: New testcase.

From-SVN: r173659
2011-05-11 14:13:38 +00:00
Nathan Froyd 515456820e split tree_type
split tree_type
gcc/ada/
	* gcc-interface/ada-tree.h (TYPE_OBJECT_RECORD_TYPE): Use TYPE_MINVAL.
	(TYPE_GCC_MIN_VALUE): Use TYPE_MINVAL.
	(TYPE_GCC_MAX_VALUE): Use TYPE_MAXVAL.

gcc/cp/
	* cp-tree.h (TYPENAME_TYPE_FULLNAME, TYPEOF_TYPE_EXPR): Use
	TYPE_VALUES_RAW.
	(UNDERLYING_TYPE_TYPE, DECLTYPE_TYPE_EXPR): Likewise.
	(DECLTYPE_TYPE_ID_EXPR_OR_MEMBER_ACCESS_P): Likewise.
	(TEMPLATE_TYPE_PARM_INDEX): Likewise.

gcc/
	* ggc-page.c (extra_order_size_table): Use struct
	tree_type_non_common.
	* lto-streamer-in.c (unpack_ts_type_value_fields): Rename to...
	(unpack_ts_type_common_value_fields): ...this.  Update comment.
	(unpack_value_fields): Adjust for renaming.
	(lto_input_ts_type_tree_pointers): Split into...
	(lto_input_ts_type_common_tree_pointer): ...this and...
	(lto_input_ts_type_non_common_tree_pointers): ...this.
	(lto_input_tree_pointers): Adjust for above split.
	* lto-streamer-out.c (pack_ts_type_value_fields): Rename to...
	(pack_ts_type_common_value_fields): ...this.  Update comment.
	(lto_output_ts_type_tree_pointers): Split into...
	(lto_output_ts_type_common_tree_pointers): ...this and...
	(lto_output_ts_type_non_common_tree_pointers): ...this.
	(lto_output_tree_pointers): Adjust for above split.
	* lto-streamer.c (check_handled_ts_structures): Mark TS_TYPE_COMMON,
	TS_TYPE_WITH_LANG_SPECIFIC, and TS_TYPE_NON_COMMON as handled.
	* stor-layout.c (vector_type_mode): Adjust location of mode field.
	* tree.h (MARK_TS_TYPE_COMMON, MARK_TS_TYPE_WITH_LANG_SPECIFIC):
	Define.
	(struct tree_type): Split into...
	(struct tree_type_common: ...this and...
	(struct tree_type_with_lang_specific): ...this and...
	(struct tree_type_non_common): ...this.  Adjust accessor macros
	accordingly.
	(TYPE_VALUES_RAW): Define.
	(union tree_node): Update for above changes.
	* tree.c (tree_node_structure_for_code) [tcc_type]: Return
	TS_TYPE_NON_COMMON.
	(initialize_tree_contains_struct) [TS_TYPE]: Use TS_TYPE_COMMON.
	Add TS_TYPE_WITH_LANG_SPECIFIC and TS_TYPE_NON_COMMON.
	(tree_code_size) [tcc_type]: Use struct tree_type_non_common.
	* treestructu.def (TS_TYPE): Remove.
	(TS_TYPE_COMMON, TS_TYPE_WITH_LANG_SPECIFIC, TS_TYPE_NON_COMMON):
	Define.

gcc/java/
	* java-tree.h (TYPE_ARGUMENT_SIGNATURE): Use TYPE_MINVAL.

gcc/lto/
	* lto.c (lto_ft_type): Use TYPE_MINVAL and TYPE_MAXVAL.  Adjust
	location of binfo field.
	(lto_fixup_prevailing_decls): Likewise.

gcc/objc/
	* objc-act.h (CLASS_NAME, CLASS_SUPER_NAME): Use proper accessors.
	(CLASS_NST_METHODS, CLASS_CLS_METHODS): Likewise.
	(PROTOCOL_NAME, PROTOCOL_NST_METHODS, PROTOCOL_CLS_METHODS): Likewise.

From-SVN: r173658
2011-05-11 13:48:55 +00:00
Jakub Jelinek b03c30822b re PR debug/48159 (ICE: SIGSEGV in build2_stat (tree.c:3802) with -ftree-loop-distribution -g)
PR debug/48159
	* tree-ssa.c (reset_debug_uses): New function.
	* tree-flow.h (reset_debug_uses): New prototype.
	* tree-data-ref.c (stmts_from_loop): Ignore debug stmts.
	* tree-loop-distribution.c (generate_loops_for_partition): Call
	reset_debug_uses on the stmts that will be removed.  Keep around
	all debug stmts, don't count them as bits in partition bitmap.
	(generate_builtin): Don't count debug stmts or labels as bits in
	partition bitmap.

	* gcc.dg/pr48159-1.c: New test.
	* gcc.dg/pr48159-2.c: New test.

From-SVN: r173656
2011-05-11 14:53:43 +02:00