Age | Commit message (Collapse) | Author | Files | Lines |
|
Public...
* typeck.c: Change copyright header to refer to version 3 of the GNU General
Public License and to point readers at the COPYING3 file and the FSF's license
web page.
* optimize.c, lang-specs.h, init.c, class.c, repo.c, decl.c, config-lang.in,
cp-tree.def, call.c, decl.h, ptree.c, Make-lang.in, method.c, rtti.c,
cp-objcp-common.c, g++spec.c, cp-objcp-common.h, except.c, error.c,
operators.def, cvt.c, tree.c, mangle.c, cp-tree.h, dump.c, search.c,
friend.c, expr.c, cp-gimplify.c, cxx-pretty-print.c, cp-lang.c, typeck2.c,
pt.c, cxx-pretty-print.h, semantics.c, name-lookup.c, lex.c, decl2.c,
name-lookup.h, parser.c: Likewise.
From-SVN: r127154
|
|
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* tree.h (enum tree_code_class): Add tcc_vl_exp.
(VL_EXP_CLASS_P): New.
(TREE_OPERAND_CHECK): Use TREE_OPERAND_LENGTH instead of
TREE_CODE_LENGTH.
(TREE_OPERAND_CHECK_CODE): Likewise.
(GIMPLE_STMT_OPERAND_CHECK): Likewise.
(TREE_RTL_OPERAND_CHECK): Likewise.
(tree_operand_check_failed): Make second parameter the whole tree
instead of its code. Fixed callers.
(VL_EXP_CHECK): New.
(TREE_OPERAND_LENGTH): New.
(VL_EXP_OPERAND_LENGTH): New.
(CALL_EXPR_FN): New.
(CALL_EXPR_STATIC_CHAIN): New.
(CALL_EXPR_ARGS): New.
(CALL_EXPR_ARG): New.
(call_expr_nargs): New.
(CALL_EXPR_ARGP): New.
(build_nt_call_list): Declare.
(build_vl_exp_stat): Declare.
(build_vl_exp): New.
(build_call_list): Declare.
(build_call_nary): Declare.
(build_call_valist): Declare.
(build_call_array): Declare.
(call_expr_arg): Declare.
(call_expr_argp): Declare.
(call_expr_arglist): Declare.
(fold_build_call_list): Declare.
(fold_build_call_list_initializer): Declare.
(fold_call_expr): Declare to replace fold_builtin.
(fold_builtin_fputs): Update to agree with modified definition.
(fold_builtin_strcpy): Likewise.
(fold_builtin_strncpy): Likewise.
(fold_builtin_memory_chk): Likewise.
(fold_builtin_stxcpy_chk): Likewise.
(fold_builtin_strncpy_chk): Likewise.
(fold_builtin_next_arg): Likewise.
(fold_build_call_expr): Declare.
(fold_builtin_call_list): Declare.
(fold_builtin_call_valist): Declare.
(build_call_expr): Declare.
(validate_arglist): Update to agree with modified definition.
(tree_operand_length): New.
(call_expr_arg_iterator): New.
(init_call_expr_arg_iterator): New.
(next_call_expr_arg): New.
(first_call_expr_arg): New.
(more_call_expr_args_p): New.
(FOR_EACH_CALL_EXPR_ARG): New.
* tree.c (tree_code_class_string): Add entries for tcc_vl_exp
and tcc_gimple_stmt.
(tree_code_size): Update documentation. Use sizeof (tree) rather
than sizeof (char *).
(tree_size): Likewise. Add case for tcc_vl_exp.
(tree_node_structure): Add case for tcc_vl_exp.
(contains_placeholder_p): Likewise.
(substitute_in_expr): Likewise.
(substitute_placeholder_in_expr): Likewise.
(stabilize_reference_1): Likewise.
(build3_stat): Remove logic for CALL_EXPRs. Replace with assertion
to diagnose breakage of this interface for constructing CALL_EXPRs.
(build_nt): Add similar assertion here.
(build_nt_call_list): New.
(simple_cst_equal) <CALL_EXPR>: Rewrite to use new accessors.
(iterative_hash_expr): Use TREE_OPERAND_LENGTH instead of
TREE_CODE_LENGTH.
(get_callee_fndecl): Use new CALL_EXPR accessors.
(tree_operand_check_failed): Change parameters to pass entire node
instead of its code, so that we can call TREE_OPERAND_LENGTH on it.
(process_call_operands): New.
(build_vl_exp_stat): New.
(build_call_list): New.
(build_call_nary): New.
(build_call_valist): New.
(build_call_array): New.
(walk_tree): Use TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
(call_expr_arglist): New.
* tree.def (CALL_EXPR): Change representation of CALL_EXPRs to use
tcc_vl_exp instead of a fixed-size tcc_expression.
* doc/c-tree.texi (CALL_EXPR): Document new representation and
accessors for CALL_EXPRs.
(AGGR_INIT_EXPR): Likewise.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* builtins.c (c_strlen): Return NULL_TREE instead of 0.
(expand_builtin_nonlocal_goto): Change parameter to be entire
CALL_EXPR instead of an arglist. Use new CALL_EXPR accessors.
(expand_builtin_prefetch): Likewise.
(expand_builtin_classify_type): Likewise.
(mathfn_built_in): Return NULL_TREE instead of 0.
(expand_errno_check): Use new CALL_EXPR accessors.
(expand_builtin_mathfn): Use new CALL_EXPR accessors and constructors.
Return NULL_RTX instead of 0.
(expand_builtin_mathfn_2): Likewise.
(expand_builtin_mathfn_3): Likewise.
(expand_builtin_interclass_mathfn): Likewise.
(expand_builtin_sincos): Likewise.
(expand_builtin_cexpi): Likewise.
(expand_builtin_int_roundingfn): Likewise.
(expand_builtin_int_roundingfn_2): Likewise.
(expand_builtin_pow): Likewise.
(expand_builtin_powi): Likewise.
(expand_builtin_strlen): Pass entire CALL_EXPR as parameter instead
of arglist, fixing callers appropriately. Use new CALL_EXPR
accessors and constructors. Return NULL_RTX instead of 0.
(expand_builtin_strstr): Likewise.
(expand_builtin_strchr): Likewise.
(expand_builtin_strrchr): Likewise.
(expand_builtin_strpbrk): Likewise.
(expand_builtin_memcpy): Likewise.
(expand_builtin_mempcpy): Likewise.
(expand_builtin_mempcpy_args): New.
(expand_builtin_memmove): Similarly to expand_builtin_mempcpy.
(expand_builtin_memmove_args): New.
(expand_builtin_bcopy): Similarly to expand_builtin_mempcpy.
(expand_movstr): Likewise.
(expand_builtin_strcpy): Likewise.
(expand_builtin_strcpy_args): New.
(expand_builtin_stpcpy): Similarly to expand_builtin_strcpy.
(expand_builtin_strncpy): Likewise.
(expand_builtin_memset): Likewise.
(expand_builtin_memset_args): New.
(expand_builtin_bzero): Similarly to expand_builtin_memset.
(expand_builtin_memcmp): Likewise.
(expand_builtin_strcmp): Likewise.
(expand_builtin_strncmp): Likewise.
(expand_builtin_strcat): Likewise.
(expand_builtin_strncat): Likewise.
(expand_builtin_strspn): Likewise.
(expand_builtin_strcspn): Likewise.
(expand_builtin_args_info): Likewise.
(expand_builtin_va_start): Likewise.
(gimplify_va_arg_expr): Likewise.
(expand_builtin_va_end): Likewise.
(expand_builtin_va_copy): Likewise.
(expand_builtin_frame_address): Likewise.
(expand_builtin_alloca): Likewise.
(expand_builtin_bswap): Likewise.
(expand_builtin_unop): Likewise.
(expand_builtin_fputs): Likewise.
(expand_builtin_expect): Likewise.
(expand_builtin_fabs): Likewise.
(expand_builtin_copysign): Likewise.
(expand_builtin_printf): Likewise.
(expand_builtin_fprintf): Likewise.
(expand_builtin_sprintf): Likewise.
(expand_builtin_init_trampoline): Likewise.
(expand_builtin_signbit): Likewise.
(expand_builtin_fork_or_exec): Likewise.
(expand_builtin_sync_operation): Likewise.
(expand_builtin_compare_and_swap): Likewise.
(expand_builtin_lock_test_and_set): Likewise.
(expand_builtin_lock_release): Likewise.
(expand_builtin): Likewise.
(builtin_mathfn_code): Likewise.
(fold_builtin_constant_p): Pass call arguments individually instead
of as an arglist, fixing callers appropriately. Use new CALL_EXPR
accessors and constructors. Return NULL_TREE instead of 0.
(fold_builtin_expect): Likewise.
(fold_builtin_classify_type): Likewise.
(fold_builtin_strlen): Likewise.
(fold_builtin_nan): Likewise.
(integer_valued_real_p): Likewise.
(fold_trunc_transparent_mathfn): Likewise.
(fold_fixed_mathfn): Likewise.
(fold_builtin_cabs): Likewise.
(fold_builtin_sqrt): Likewise.
(fold_builtin_cbrt): Likewise.
(fold_builtin_cos): Likewise.
(fold_builtin_cosh): Likewise.
(fold_builtin_tan): Likewise.
(fold_builtin_sincos): Likewise.
(fold_builtin_cexp): Likewise.
(fold_builtin_trunc): Likewise.
(fold_builtin_floor): Likewise.
(fold_builtin_ceil): Likewise.
(fold_builtin_round): Likewise.
(fold_builtin_int_roundingfn): Likewise.
(fold_builtin_bitop): Likewise.
(fold_builtin_bswap): Likewise.
(fold_builtin_logarithm): Likewise.
(fold_builtin_hypot): Likewise.
(fold_builtin_pow): Likewise.
(fold_builtin_powi): Likewise.
(fold_builtin_exponent): Likewise.
(fold_builtin_memset): Likewise.
(fold_builtin_bzero): Likewise.
(fold_builtin_memory_op): Likewise.
(fold_builtin_bcopy): Deleted; call site changed to invoke
fold_builtin_memory_op directly.
(fold_builtin_strcpy): Similarly as for fold_builtin_memory_op.
(fold_builtin_strncpy): Likewise.
(fold_builtin_memcmp): Likewise.
(fold_builtin_strcmp): Likewise.
(fold_builtin_strncmp): Likewise.
(fold_builtin_signbit): Likewise.
(fold_builtin_copysign): Likewise.
(fold_builtin_isascii): Likewise.
(fold_builtin_toascii): Likewise.
(fold_builtin_isdigit): Likewise.
(fold_builtin_fabs): Likewise.
(fold_builtin_abs): Likewise.
(fold_builtin_fmin_fmax): Likewise.
(fold_builtin_carg): Likewise.
(fold_builtin_classify): Likewise.
(fold_builtin_unordered_cmp): Likewise.
(fold_builtin_0, fold_builtin_2, fold_builtin_3, fold_builtin_4):
New functions split out from fold_builtin_1.
(fold_builtin_n): New.
(fold_builtin_varargs): New.
(fold_builtin): Deleted. Most callers changed to use fold_call_expr
instead.
(fold_call_expr): New.
(build_function_call_expr): Rewrite to use new helper function.
(fold_builtin_call_list): New.
(build_call_expr): New.
(fold_builtin_call_valist): New.
(rewrite_call_expr): New.
(validate_arg): New.
(validate_arglist): Change parameter to be entire CALL_EXPR instead
of an arglist. Change return type to bool. Use new CALL_EXPR
accessors.
(fold_builtin_strstr): Pass call arguments individually instead
of as an arglist, fixing callers appropriately. Use new CALL_EXPR
accessors and constructors. Return NULL_TREE instead of 0.
(fold_builtin_strchr): Likewise.
(fold_builtin_strrchr): Likewise.
(fold_builtin_strpbrk): Likewise.
(fold_builtin_strcat): Likewise.
(fold_builtin_strncat): Likewise.
(fold_builtin_strspn): Likewise.
(fold_builtin_strcspn): Likewise.
(fold_builtin_fputs): Likewise.
(fold_builtin_next_arg): Likewise.
(fold_builtin_sprintf): Likewise.
(expand_builtin_object_size): Use new CALL_EXPR accessors. Use
NULL_RTX instead of 0.
(expand_builtin_memory_chk): Likewise.
(maybe_emit_chk_warning): Likewise.
(maybe_emit_sprintf_chk_warning): Likewise.
(fold_builtin_object_size): Pass call arguments individually instead
of as an arglist, fixing callers appropriately. Use new CALL_EXPR
accessors and constructors. Return NULL_TREE instead of 0.
(fold_builtin_memory_chk): Likewise.
(fold_builtin_stxcpy_chk): Likewise.
(fold_builtin_strncpy_chk): Likewise.
(fold_builtin_strcat_chk): Likewise.
(fold_builtin_strcat_chk): Likewise.
(fold_builtin_strncat_chk): Likewise.
(fold_builtin_sprintf_chk): Likewise.
(fold_builtin_snprintf_chk): Likewise.
(fold_builtin_printf): Likewise.
(fold_builtin_vprintf): Likewise.
* fold-const.c (negate_expr_p): Use new CALL_EXPR accessors and
constructors.
(operand_equal_p): Add separate tcc_vl_exp/CALL_EXPR case.
(make_range): Use TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
(extract_muldiv_1): Add VL_EXP_CLASS_P case.
(fold_mathfn_compare): Use new CALL_EXPR accessors and constructors.
(fold_unary): Likewise.
(fold_binary): Likewise.
(fold_ternary): Remove CALL_EXPR case, since they are no longer
ternary expressions.
(fold): Add logic for tcc_vl_exp.
(fold_checksum_tree): Make it know about tcc_vl_exp. Use
TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
(fold_build3_stat): Add assertion to flag broken interface for
constructing CALL_EXPRs.
(fold_build_call_list): New.
(fold_build_call_list_initializer): New.
(tree_expr_nonnegative_p): Use new CALL_EXPR accessors and
constructors.
(fold_strip_sign_ops): Likewise.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* tree-dump.c (dequeue_and_dump) <CALL_EXPR>: Use new CALL_EXPR
accessors and dump arguments explicitly.
* tree-pretty-print.c (do_niy): Use TREE_OPERAND_LENGTH instead of
TREE_CODE_LENGTH.
(dump_generic_node): Use new CALL_EXPR accessors and walk arguments
explicitly.
(print_call_name): Use new CALL_EXPR accessors.
* print-tree.c (print_node): Add case tcc_vl_exp. Print
CALL_EXPR arguments explicitly instead of as a list. Use
TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
* tree-vrp.c (stmt_interesting_for_vrp): Use new CALL_EXPR accessors.
(vrp_visit_stmt): Likewise.
* tree-ssa-loop-im.c (outermost_invariant_loop_expr): Make it
know about tcc_vl_exp. Use TREE_OPERAND_LENGTH instead of
TREE_CODE_LENGTH.
(force_move_till_expr): Likewise.
* targhooks.c (default_external_stack_protect_fail): Use
build_call_expr instead of build_function_call_expr.
(default_hidden_stack_protect_fail): Likewise.
* tree-complex.c (expand_complex_libcall): Use build_call_expr to
build the call.
* cgraphbuild.c (build_cgraph_edges): Use new CALL_EXPR accessors
and walk arguments explicitly.
* tree-ssa-loop-niter.c (simplify_replace_tree): Use
TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
(expand_simple_operations): Likewise.
(infer_loop_bounds_from_array): Use new CALL_EXPR accessors.
* gengtype.c (adjust_field_tree_exp): Use TREE_OPERAND_LENGTH instead
of TREE_CODE_LENGTH.
(walk_type): Tweak walking of arrays not to blow up on CALL_EXPRs.
* optabs.c (expand_widen_pattern-expr): Use TREE_OPERAND_LENGTH
instead of TREE_CODE_LENGTH.
* value_prof.c (tree_ic): Use new CALL_EXPR accessors.
(tree_ic_transform): Likewise.
(interesting_stringop_to_profile_p): Pass entire CALL_EXPR as
parameter instead of arglist. Fix callers.
(tree_stringop_fixed_value): Use new CALL_EXPR accessors.
(tree_stringops_transform): Likewise.
(tree_indirect_call_to_profile): Likewise.
(tree_stringops_values_to_profile): Likewise.
* tree-tailcall.c (find_tail_calls): Use new CALL_EXPR iterator.
(eliminate_tail_call): Likewise.
* ipa-cp.c (ipcp_update_callgraph): Use new CALL_EXPR accessors.
* tree-scalar-evolution.c (chrec_contains_symbols_defined_in_loop):
Use TREE_OPERAND_LENGTH and generalize to handle any number of
operands.
(instantiate_parameters_1): Can't handle tcc_vl_exp here.
* omp-low.c (build_omp_barrier): Use build_call_expr.
(lower_rec_input_clauses): Likewise.
(lower_reduction_clauses): Likewise.
(expand_parallel_call): Likewise.
(maybe_catch_exception): Likewise.
(expand_omp_for_generic): Likewise.
(expand_omp_for_static_nochunk): Likewise.
(expand_omp_sections): Likewise.
(lower_omp_single_simple): Likewise.
(lower_omp_single_copy): Likewise.
(lower_omp_master): Likewise.
(lower_omp_ordered): Likewise.
(lower_omp_critical): Likewise.
* ipa-reference.c (check-call): Use new CALL_EXPR iterator.
(scan_for_static_refs): Create tcc_vl_exp case for CALL_EXPR.
* tree-gimple.c (is_gimple_call_addr): Fix doc.
(recalculate_side_effects): Use TREE_OPERAND_LENGTH instead of
TREE_CODE_LENGTH. Add tcc_vl_exp case.
* tree-chrec.c (chrec_contains_symbols): Use TREE_OPERAND_LENGTH
and generalize to handle any number of operands.
(chrec_contains_undetermined): Likewise.
(tree_contains_chrecs): Likewise.
(evolution_function_is_invariant_rec_p): Use TREE_OPERAND_LENGTH.
* cgraphunit.c (update_call_expr): Use new CALL_EXPR accessors.
* tree-ssa-ccp.c (ccp_fold): Use new CALL_EXPR accessors. Use
fold_call_expr instead of fold_builtin.
(ccp_fold_builtin): Likewise. Update calls into builtins.c to
match declarations there.
(fold_stmt): Use new CALL_EXPR constructor and accessors. Doc
updates.
* tree-ssa-loop-ivopts.c (expr_invariant_in_loop_p): Use
TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
* ipa-pure-const.c (check_call): Use new CALL_EXPR accessors.
(scan_function): Add case tcc_vl_exp for CALL_EXPR.
* tree-stdarg.c (execute_optimize_stdarg): Use new CALL_EXPR
accessors.
* tree-ssa-math-opts.c (execute_cse_sincos_1): Use build_call_expr.
(execute_cse_sincos): Use new CALL_EXPR accessors.
* tree-ssa-alias.c (find_used_portions): Use new CALL_EXPR iterator.
* gimple-low.c (lower_function_body): Use build_call_expr.
(lower_builtin_setjmp): Likewise.
* expr.c (emit_block_move_via_libcall): Use build_call_expr.
(set_storage_via_libcall): Likewise.
(safe_from_p): Add tcc_vl_exp case. Use TREE_OPERAND_LENGTH
instead of TREE_CODE_LENGTH.
(expand_expr_real_1): Use new CALL_EXPR accessors.
* tree-browser.c (store_child_info): Use TREE_OPERAND_LENGTH and
generalize to handle any number of operands.
(TB_parent_eq): Likewise.
* predict.c (expr_expected_value): Use new CALL_EXPR accessors.
(strip_builtin_expect): Likewise.
* function.c (gimplify_parameters): Use build_call_expr.
* tree-vectorizer.c (vect_is_simple_reduction): Use TREE_OPERAND_LENGTH
instead of TREE_CODE_LENGTH.
* ipa-type-escape.c (check_call): Use new CALL_EXPR iterators.
(scan_for_refs): Add case tcc_vl_exp for CALL_EXPR.
* tree-data-ref.c (get_references_in_stmt): Use new CALL_EXPR
iterators.
* gimplify.c (build_stack_save_restore): Use build_call_expr.
(gimplify_decl_expr): Likewise.
(gimplify_call_expr): Use fold_call_expr instead of fold_builtin.
Use new CALL_EXPR iterators.
(gimplify_modify_expr_to_memcpy): Use build_call_expr.
(gimplify_modify_expr_to_memset): Likewise.
(gimplify_variable_sized_compare): Likewise.
(gimplify_omp_atomic_fetch_op): Likewise.
(gimplify_omp_atomic_pipeline): Likewise.
(gimplify_omp_atomic_mutex): Likewise.
(gimplify_function_tree): Likewise.
* calls.c (alloca_call_p): Use new CALL_EXPR accessors.
(call_expr_flags): Likewise.
(expand_call): Likewise.
* except.c (expand_builtin_eh_return_data_regno): Pass entire
CALL_EXPR as parameter instead of arglist. Use new CALL_EXPR
accessors.
* coverage.c (create_coverage): Use build_call_expr.
* tree-ssa-pre.c (expression_node_pool, list_node_pool): Delete.
(temp_call_expr_obstack): New.
(pool_copy_list): Delete.
(temp_copy_call_expr): New.
(phi_translate): Add case tcc_vl_exp for CALL_EXPR. Use new
CALL_EXPR accessors. Get rid of special goo for copying argument
lists and use temp_copy_call_expr instead.
(valid_in_sets): Add case tcc_vl_exp for CALL_EXPR. Use new
CALL_EXPR accessors.
(create_expression_by_pieces): Likewise. Use build_call_array
to construct the result instead of fold_build3.
(create_value_expr_from): Add tcc_vl_exp. Delete special goo for
dealing with argument lists.
(init_pre): Remove references to expression_node_pool and
list_node_pool. Init temp_call_expr_obstack instead.
(fini_pre): Remove references to expression_node_pool and
list_node_pool.
* tree-sra.c (sra_walk_call_expr): Use new CALL_EXPR accessors
and walk arguments explicitly instead of as a list.
* tree-mudflap.c (mf_build_check_statement_for): Use build_call_expr.
(mx_register_decls): Likewise.
(mudflap_register_call): Likewise.
(mudflap_finish_file): Likewise.
* ipa-prop.c (ipa_callsite_compute_count): Use new CALL_EXPR accessors.
(ipa_callsite_compute_param): Likewise.
* tree-vect-patterns.c (vect_recog_pow_pattern): Use new CALL_EXPR
accessors and constructor.
* tree-nested.c (convert_nl_goto_reference): Use new CALL_EXPR
accessors and constructor.
(convert_tramp_reference): Likewise.
(convert_call_expr): Likewise.
(finalize_nesting_tree_1): Likewise.
* tree-ssa.c (tree_ssa_useless_type_conversion): Use new CALL_EXPR
accessors.
* tree-ssa-loop-prefetch.c (issue_prefetch_ref): Use build_call_expr.
* tree-inline.c (initialize_inlined_parameters): Pass entire
CALL_EXPR as parameter instead of arglist. Use new CALL_EXPR
accessors.
(estimate_num_insns_1): Use new CALL_EXPR accessors.
(expand_call_inline): Tidy up call to initialize_inlined_parameters.
* tree-vect-transform.c (vect_create_epilog_for_reduction): Use
TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
(vectorizable_reduction): Likewise.
(vectorizable_call): Use new CALL_EXPR iterators.
(vectorizable_conversion): Use build_call_expr.
(vectorizable_operation): Use TREE_OPERAND_LENGTH.
(vect_gen_widened_results_half): Use build_call_expr.
(vect_setup_realignment): Likewise.
(vectorizable_live_operation): Use TREE_OPERAND_LENGTH.
* tree-object-size.c (alloc_object_size): Use new CALL_EXPR accessors.
(pass_through_call): Likewise.
(compute_object_sizes): Likewise. Use fold_call_expr instead of
fold_builtin.
* tree-profile.c (tree_gen_interval_profiler): Use build_call_expr.
(tree_gen_pow2_profiler): Likewise.
(tree_gen_one_value_profiler): Likewise.
(tree_gen_ic_func_profiler): Likewise.
(tree_gen_average_profiler): Likewise.
(tree_gen_ior_profiler): Likewise.
* tree-ssa-structalias.c (get_constraint_for): Add case tcc_vl_exp.
(find_func_aliases): Use new CALL_EXPR accessors. Add case
tcc_vl_exp. Use TREE_OPERAND_LENGTH instead of TREE_CODE_LENGTH.
* tree-ssa-reassoc.c (get_rank): Use TREE_OPERAND_LENGTH instead
of TREE_CODE_LENGTH.
* stmt.c (warn_if_unused_value): Use TREE_OPERAND_LENGTH instead
of TREE_CODE_LENGTH.
* convert.c (convert_to_real): Use new CALL_EXPR accessors and
constructor.
(convert_to_integer): Likewise.
* tree-ssa-operands.c (get_call_expr_operands): Use new CALL_EXPR
accessors.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* config/alpha/alpha.c (alpha_expand_builtin): Use new CALL_EXPR
accessors.
* config/frv/frv.c (frv_expand_builtin): Likewise.
* config/s390/s390.c (s390_expand_builtin): Likewise.
* config/sparc/sparc.c (sparc_gimplify_va_arg): Use build_call_expr.
(sparc_expand_builtin): Use new CALL_EXPR accessors.
* config/i386/i386.c (ix86_function_ok_for_sibcall): Likewise.
(ix86_expand_binop_builtin): Pass entire CALL_EXPR as parameter
instead of arglist. Use new CALL_EXPR accessors on it. Fix callers.
(ix86_expand_store_builtin): Likewise.
(ix86_expand_unop_builtin): Likewise.
(ix86_expand_unop1_builtin): Likewise.
(ix86_expand_sse_compare): Likewise.
(ix86_expand_sse_comi): Likewise.
(ix86_expand_vec_init_builtin): Likewise.
(ix86_expand_vec_ext_builtin): Likewise.
(ix86_expand_vec_set_builtin): Likewise.
(ix86_expand_builtin): Use new CALL_EXPR accessors.
* config/sh/sh.c (sh_expand_builtin): Use new CALL_EXPR accessors.
* config/c4x/c4x.c (c4x_expand_builtin): Likewise.
* config/iq2000/iq2000.c (expand_one_builtin): Pass entire CALL_EXPR
instead of arglist. Use new CALL_EXPR accessors. Fix callers.
(iq2000_expand_builtin): Use new CALL_EXPR accessors.
* config/rs6000/rs6000-c.c (altivec_build_resolved_builtin): Use
build_call_expr.
* config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Likewise.
(rs6000_expand_unop_builtin): Pass entire CALL_EXPR instead of
arglist. Use new CALL_EXPR accessors. Fix callers.
(altivec_expand_abs_builtin): Likewise.
(rs6000_expand_binop_builtin): Likewise.
(altivec_expand_predicate_builtin): Likewise.
(altivec_expand_lv_builtin): Likewise.
(spe_expand_stv_builtin): Likewise.
(altivec_expand_stv_builtin): Likewise.
(rs6000_expand_ternop_builtin): Likewise.
(altivec_expand_ld_builtin): Use new CALL_EXPR accessors.
(altivec_expand_st_builtin): Likewise.
(altivec_expand_dst_builtin): Likewise.
(altivec_expand_vec_init_builtin): Pass entire CALL_EXPR instead of
arglist. Use new CALL_EXPR accessors. Fix callers.
(altivec_expand_vec_set_builtin): Likewise.
(altivec_expand_vec_ext_builtin): Likewise.
(altivec_expand_builtin): Use new CALL_EXPR accessors.
(spe_expand_builtin): Likewise.
(spe_expand_predicate_builtin): Pass entire CALL_EXPR instead of
arglist. Use new CALL_EXPR accessors. Fix callers.
(spe_expand_evsel_builtin): Likewise.
(rs6000_expand_builtin): Use new CALL_EXPR accessors. VCFUX and
FCFSX cases must construct whole new CALL_EXPR, not just arglist.
* config/arm/arm.c (arm_expand_binop_builtin): Pass entire CALL_EXPR
instead of arglist. Use new CALL_EXPR accessors. Fix callers.
(arm_expand_unop_builtin): Likewise.
(arm_expand_builtin): Use new CALL_EXPR accessors.
* config/mips/mips.c (mips_expand_builtin): Use new CALL_EXPR
accessors.
* config/bfin/bfin.c (bfin_expand_binop_builtin): Pass entire CALL_EXPR
instead of arglist. Use new CALL_EXPR accessors. Fix callers.
(bfin_expand_unop_builtin): Likewise.
(bfin_expand_builtin): Use new CALL_EXPR accessors.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* c-semantics.c (build_stmt): Add internal diagnostic check.
* c-pretty-print.c (pp_c_postfix_expression): Use new CALL_EXPR
accessors. Print arguments explicitly instead of as a list.
* c-typeck.c (build_function_call): Use new CALL_EXPR constructors.
* c-omp.c (c_finish_omp_barrier): Use build_call_expr.
(c_finish_omp_flish): Likewise.
* c-common.c (verify_tree): Use new CALL_EXPR accessors. Traverse
arguments explicitly instead of as a list. Use TREE_OPERAND_LENGTH
instead of TREE_CODE_LENGTH.
(check_function_arguments_recurse): Use new CALL_EXPR accessors.
(c_warn_unused_result): Likewise.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* cp-tree.def (AGGR_INIT_EXPR): Adjust documentation.
Change class to tcc_vl_exp.
* call.c (build_call): Use build_call_list instead
of build3.
(build_over_call): Likewise.
(build_new_method_call): Use build_min_non_dep_call_list
instead of build_min_non_dep.
* error.c (dump_call_expr_args): New function.
(dump_aggr_init_expr_args): New function.
(dump_expr) <AGGR_INIT_EXPR, CALL_EXPR, INDIRECT_REF>: Use them.
Update to use new CALL_EXPR and AGGR_INIT_EXPR accessor macros.
* cvt.c (convert_to_void): Use build_call_array instead
of build3; use new AGGR_INIT_EXPR accessor macros.
* mangle.c (write_expression): Use TREE_OPERAND_LENGTH
instead of TREE_CODE_LENGTH.
* dump.c (cp_dump_tree) <AGGR_INIT_EXPR>: Update to use new
AGGR_INIT_EXPR accessor macros.
* cp-gimplify.c (cp_gimplify_init_expr): Use
AGGR_INIT_EXPR_SLOT to set the slot operand.
* cp-tree.h (AGGR_INIT_EXPR_FN): New macro.
(AGGR_INIT_EXPR_SLOT): New macro.
(AGGR_INIT_EXPR_ARG): New macro.
(aggr_init_expr_nargs): New macro.
(AGGR_INIT_EXPR_ARGP): New macro.
(aggr_init_expr_arg_iterator): New.
(init_aggr_init_expr_arg_iterator): New.
(next_aggr_init_expr_arg): New.
(first_aggr_init_expr_arg): New.
(more_aggr_init_expr_args_p): New.
(FOR_EACH_AGGR_INIT_EXPR_ARG): New.
(stabilize_aggr_init): New declaration.
(build_min_non_dep_call_list): Likewise.
* tree.c (process_aggr_init_operands): New function.
(build_aggr_init_array) New function.
(build_cplus_new): Update to use new CALL_EXPR and
AGGR_INIT_EXPR accessor macros. Replace use of build3 with
build_aggr_init_array.
(build_min_non_dep_call_list) New function.
(build_min_nt): Assert input code parameter is not a variable
length expression class.
(build_min, build_min_non_dep): Likewise.
(cp_tree_equal) <CALL_EXPR>: Iterate through the arguments
to check for equality instead of recursing. Handle tcc_vl_exp
tree code classes.
(stabilize_call): Update to only handle CALL_EXPRs, not
AGGR_INIT_EXPRs; use new CALL_EXPR accessor macros.
(stabilize_aggr_init): New function.
(stabilize_init): Use it.
* cxx-pretty-print.c (pp_cxx_postfix_expression)
<AGGR_INIT_EXPR, CALL_EXPR>: Update to use new CALL_EXPR and
AGGR_INIT_EXPR accessor macros and argument iterators.
* pt.c (tsubst_copy) <CALL_EXPR>: Replace build_nt with
build_vl_exp. Iterate through the operands, recursively
processing each one.
(tsubst_copy_and_build) <CALL_EXPR>: Update to use new
CALL_EXPR accessor macros.
(value_dependent_expression_p) <default>: Handle tcc_vl_exp
tree code classes. Use TREE_OPERAND_LENGTH instead of
TREE_CODE_LENGTH.
* semantics.c (finish_call_expr): Use build_nt_call_list
instead of build_nt.
(simplify_aggr_init_expr): Update to use new AGGR_INIT_EXPR
accessor macros. Use build_call_array to construct the
CALL_EXPR node instead of build3
* decl2.c (build_offset_ref_call_from_tree): Use
build_nt_call_list and build_min_non_dep_call_list instead
of build_min_nt and build_min_non_dep.
* parser.c (cp_parser_postfix_expression) <CPP_OPEN_PAREN>:
Use build_nt_call_list instead of build_min_nt.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* java-tree.h (BUILD_MONITOR_ENTER): Use build_call_nary instead
of build3.
(BUILD_MONITOR_EXIT): Likewise.
* java-gimplify.c (java_gimplify_component_ref): Use build_call_expr.
(java_gimplify_modify_expr): Likewise.
* class.c (cache_this_class_ref): Use build_call_expr.
(build_static_field_ref): Likewise.
(emit_indirect_register_classes): Likewise.
(emit_register_classes): Likewise.
* resource.c (write_resource_constructor): Use build_call_expr.
* builtins.c (builtin_creator_function): Change interpretation of
the second parameter to be the whole CALL_EXPR instead of the arglist.
(max_builtin): Tweak parameter list. Use new CALL_EXPR accessors.
(min_builtin): Likewise.
(abs_builtin): Likewise.
(java_build_function_call_expr): Likewise.
(convert_real): Likewise.
(UNMARSHAL3): Likewise.
(UNMARSHAL4): Likewise.
(UNMARSHAL5): Likewise.
(build_arglist_for_builtin): Delete. Fix callers to use
build_call_expr instead.
(putObject_builtin): Tweak parameter list. Use new CALL_EXPR
accessors.
(compareAndSwapInt_builtin): Likewise.
(compareAndSwapLong_builtin): Likewise.
(compareAndSwapObject_builtin): Likewise.
(putVolatile_builtin): Likewise.
(getVolatile_builtin): Likewise.
(VMSupportsCS8_builtin): Likewise.
(check_for_builtin): Pass entire CALL_EXPR to builtin expander
instead of arglist.
* expr.c (build_java_athrow): Use build_call_nary instead of build3.
(build_java_throw_out_of_bounds_exception): Likewise.
(java_check_reference): Likewise.
(build_java_arraystore_check): Likewise.
(build_newarray): Likewise.
(build_anewarray): Likewise.
(expand_java_multinewarray): Use build_call_list instead of build3.
(build_java_monitor): Use build_call_nary instead of build3.
(java_create_object): Likewise.
(expand_java_NEW): Likewise.
(build_instanceof): Likewise.
(expand_java_CHECKCAST): Likewise.
(build_java_soft_divmod): Likewise.
(build_java_binop): Likewise.
(build_field_ref): Likewise.
(build_class_init): Likewise.
(rewrite_arglist_getcaller): Use build_call_expr.
(build_invokeinterface): Use build_call_nary instead of build3.
(expand_invoke): Use build_call_list instead of build3.
(build_jni_stub): Use build_call_nary, build_call_list, or
build_call_expr instead of build3.
(expand_java_field_op): Use build_call_expr instead of build3.
(force_evaluation_order): Use new CALL_EXPR accessors.
* lang.c (java_get_callee_fndecl): Use new CALL_EXPR accessors.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* objc-act.c (receiver_is_class_object): Use new CALL_EXPR accessors.
(objc_get_callee_fndecl): Likewise.
2007-02-15 Sandra Loosemore <sandra@codesourcery.com>
Brooks Moses <brooks.moses@codesourcery.com>
Lee Millward <lee.millward@codesourcery.com>
* trans-expr.c (gfc_conv_power_op): Use build_call_expr.
(gfc_conv_string_tmp): Likewise.
(gfc_conv_concat_op): Likewise.
(gfc_build_compare_string): Likewise.
(gfc_conv_function_call): Use build_call_list instead of build3.
* trans-array.c (gfc_trans_allocate_array_storage): Use
build_call_expr.
(gfc_grow_array): Likewise.
(gfc_trans_array_ctor_element): Likewise.
(gfc_trans_array_constructor_value): Likewise.
(gfc_array_allocate): Likewise.
(gfc_array_deallocate): Likewise.
(gfc_trans_auto_array_allocation): Likewise.
(gfc_trans_dummy_array_bias): Likewise.
(gfc_conv_array_parameter): Likewise.
(gfc_trans_dealloc_allocated): Likewise.
(gfc_duplicate_allocatable): Likewise.
* trans-openmp.c (gfc_trans_omp_barrier): Use build_call_expr.
(gfc_trans_omp_flush): Likewise.
* trans-stmt.c (gfc_conv_elementel_dependencies): Use build_call_expr.
(gfc_trans_pause): Likewise.
(gfc_trans_stop): Likewise.
(gfc_trans_character_select): Likewise.
(gfc_do_allocate): Likewise.
(gfc_trans_assign_need_temp): Likewise.
(gfc_trans_pointer_assign_need_temp): Likewise.
(gfc_trans_forall_1): Likewise.
(gfc_trans_where_2): Likewise.
(gfc_trans_allocate): Likewise.
(gfc_trans_deallocate): Likewise.
* trans.c (gfc_trans_runtime_check): Use build_call_expr.
* trans-io.c (gfc_trans_open): Use build_call_expr.
(gfc_trans_close): Likewise.
(build_filepos): Likewise.
(gfc_trans_inquire): Likewise.
(NML_FIRST_ARG): Delete.
(NML_ADD_ARG): Delete.
(transfer_namelist_element): Use build_call_expr.
(build_dt): Likewise.
(gfc_trans_dt_end): Likewise.
(transfer_expr): Likewise.
(transfer_array-desc): Likewise.
* trans-decl.c (gfc_generate_function_code): Use build_call_expr.
(gfc_generate_constructors): Likewise.
* trans-intrinsic.c (gfc_conv_intrinsic_ctime): Use build_call_expr.
(gfc_conv_intrinsic_fdate): Likewise.
(gfc_conv_intrinsic_ttynam): Likewise.
(gfc_conv_intrinsic_array_transfer): Likewise.
(gfc_conv_associated): Likewise.
(gfc_conv_intrinsic_si_kind): Likewise.
(gfc_conv_intrinsic_trim): Likewise.
(gfc_conv_intrinsic_repeat: Likewise.
(gfc_conv_intrinsic_iargc): Likewise.
Co-Authored-By: Brooks Moses <brooks.moses@codesourcery.com>
Co-Authored-By: Lee Millward <lee.millward@codesourcery.com>
From-SVN: r122018
|
|
* tree-dump.h (dump_string_field): Declare.
* tree-dump.c: Use it instead of dump_string.
(dump_string_field): Make non-static.
cp/
* dump.c: Use dump_string_field.
From-SVN: r101547
|
|
From-SVN: r101312
|
|
From-SVN: r100965
|
|
From-SVN: r100952
|
|
* cp-tree.def (UNARY_PLUS_EXPR): New C++ unary tree code.
* parser.c (cp_parser_unary_expression): Use UNARY_PLUS_EXPR instead
of CONVERT_EXPR.
(cp_parser_unary_expression): Likewise.
* typeck.c (build_unary_op): Likewise.
* call.c (add_builtin_candidate, build_new_op): Likewise.
* error.c (dump_expr): Likewise.
* pt.c (tsubst_copy, tsubst_copy_and_build): Likewise.
* decl.c (ambi_op_p, grok_op_properties): Likewise.
* dump.c (dump_op): Likewise.
* lex.c (init_operators): Likewise.
* operators.def ("+"): Likewise.
* cp-gimplify.c (cp_gimplify_expr): Handle UNARY_PLUS_EXPR like a
conversion, if the result and argument types differ.
* tree.c (fold_if_not_in_template): Fold UNARY_PLUS_EXPR much
like a NOP_EXPR when !processing_template_decl.
* cxx-pretty-print.c (pp_cxx_cast_expression): Prototype.
(pp_cxx_unary_expression): Handle new UNARY_PLUS_EXPR tree code.
Co-Authored-By: Giovanni Bajo <giovannibajo@gcc.gnu.org>
From-SVN: r100285
|
|
./ * c-common.def (EXPR_STMT): Remove, moved to C++ frontend.
* c-common.h (EXPR_STMT_EXPR): Don't define.
(c_common_stmt_codes): Don't define.
* c-dump.c (c_dump_tree): Remove EXPR_STMT case.
* c-gimplify.c (gimplify_expr_stmt): Remove.
(c_gimplify_expr): Remove EXPR_STMT case.
* c-objc-common.c (c_objc_common_init): Remove stmt_codes and call
to INIT_STATEMENT_CODES.
* c-pretty-print.c (pp_c_statement): Just call dump_generic_node.
cp/
* cp-tree.def: Add EXPR_STMT.
* cp-tree.h (cp_stmt_codes): Add EXPR_STMT.
(EXPR_STMT_EXPR): Define.
* cp-gimplify.c: Include "flags.h".
(gimplify_expr_stmt): New static function.
(cp_gimplify_expr): Handle EXPR_STMT.
* cxx-pretty-print.c (pp_cxx_statement): Use pp_cxx_expression
rather than pp_expression.
(pp_cxx_statement): Handle EXPR_STMT.
* dump.c (cp_dump_tree): Handle EXPR_STMT.
* lex.c (cxx_init): Don't use c_common_stmt_codes in stmt_codes
initializer.
From-SVN: r98731
|
|
./ * c-common.def: Remove STMT_EXPR (moved to cp/cp-tree.def).
* c-common.h (STMT_EXPR_STMT): Don't define.
(STMT_EXPR_NO_SCOPE): Don't define.
* c-dump.c (c_dump_tree): Don't handle STMT_EXPR.
* c-pretty-print.c (pp_c_primary_expression): Likewise.
(pp_c_expression): Likewise.
cp/
* cp-tree.def: Add STMT_EXPR.
* cp-tree.h (STMT_EXPR_NO_SCOPE): Define.
(STMT_EXPR_STMT): Define.
* cxx-pretty-print.c (pp_cxx_primary_expression): Handle
STMT_EXPR.
(pp_cxx_expression): Likewise.
(pp_cxx_statement): Call pp_cxx_statement, not pp_statement.
* dump.c (cp_dump_tree): Handle STMT_EXPR.
From-SVN: r98469
|
|
./ * c-common.def: Move FOR_STMT, WHILE_STMT, DO_STMT, BREAK_STMT,
CONTINUE_STMT, and SWITCH_STMT to cp/cp-tree.def.
* c-common.h (WHILE_COND, WHILE_BODY): Move to cp/cp-tree.h.
(DO_COND, DO_BODY): Likewise.
(FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY): Likewise.
(SWITCH_STMT_COND, SWITCH_STMT_BODY, SWITCH_STMT_TYPE): Likewise.
(c_common_stmt_codes): Remove FOR_STMT, WHILE_STMT, DO_STMT,
BREAK_STMT, CONTINUE_STMT, and SWITCH_STMT.
(build_continue_stmt, build_break_stmt): Don't declare.
(c_do_switch_warnings): Update declaration.
* c-gimplify.c (enum bc_t): Remove.
(struct c_gimplify_ctx, ctxp): Remove.
(push_context, pop_context): Remove static functions.
(c_genericize): Don't call push_context or pop_context.
(begin_bc_block, finish_bc_block): Remove static functions.
(build_bc_goto): Likewise.
(gimplify_c_loop): Likewise.
(gimplify_for_stmt, gimplify_while_stmt): Likewise.
(gimplify_do_stmt, gimplify_switch_stmt): Likewise.
(c_gimplify_expr): Remove handling of FOR_STMT, WHILE_STMT,
DO_STMT, SWITCH_STMT, CONTINUE_STMT, BREAK_STMT.
* c-common.c (c_do_switch_warnings): Rename from
c_do_switch_warnings_1.
(c_do_switch_warnings) [old version]: Remove.
(c_do_switch_expr_warnings): Remove.
* c-typeck.c (c_finish_case): Call new c_do_switch_warnings
function instead of c_do_switch_expr_warnings.
* c-dump.c (c_dump_tree): Remove handling of BREAK_STMT,
CONTINUE_STMT, DO_STMT, FOR_STMT, SWITCH_STMT, and WHILE_STMT.
* c-pretty-print.c (pp_c_statement): Likewise.
* c-semantics.c (build_break_stmt, build_continue_stmt): Remove.
cp/
* cp-tree.def: Define FOR_STMT, WHILE_STMT, DO_STMT, BREAK_STMT,
CONTINUE_STMT, SWITCH_STMT.
* cp-tree.h (cp_stmt_codes): Add FOR_STMT, WHILE_STMT, DO_STMT,
BREAK_STMT, CONTINUE_STMT, SWITCH_STMT.
(WHILE_COND, WHILE_BODY): Define.
(DO_COND, DO_BODY): Define.
(FOR_INIT_STMT, FOR_COND, FOR_EXPR, FOR_BODY): Define.
(SWITCH_STMT_COND, SWITCH_STMT_BODY, SWITCH_STMT_TYPE): Define.
* cp-gimplify.c (enum bc_t): Define.
(struct cp_gimplify_ctx, ctxp): Define.
(push_context, pop_context): New static functions.
(begin_bc_block, finish_bc_block): New static functions.
(build_bc_goto): New static function.
(gimplify_cp_loop, gimplify_for_stmt): New static functions.
(gimplify_while_stmt, gimplify_do_stmt): Likewise.
(gimplify_switch_stmt): Likewise.
(cp_gimplify_expr): Handle FOR_STMT, WHILE_STMT, DO_STMT,
SWITCH_STMT, CONTINUE_STMT, BREAK_STMT.
(cp_genericize): Call push_context and pop_context.
* semantics.c (finish_break_stmt): Just call build_stmt
(BREAK_STMT) rather than build_break_stmt.
(finish_continue_stmt): Corresponding change.
* decl.c (pop_switch): Update call to c_do_switch_warnings for new
parameters.
* cxx-pretty-print.c (pp_cxx_statement): Handle SWITCH_STMT,
WHILE_STMT, DO_STMT, FOR_STMT, BREAK_STMT, CONTINUE_STMT.
* dump.c (cp_dump_tree): Likewise.
From-SVN: r97885
|
|
From-SVN: r89098
|
|
.: * tree.h: Include vec.h
(DEF_VEC_P(tree)): New type.
(BINFO_BASE_BINFOS, BINFO_N_BASE_BINFOS, BINFO_BASE_BINFO): Adjust.
(BINFO_BASE_APPEND, BINFO_BASE_ITERATE): New.
(BINFO_LANG_SLOT): Remove.
(BINFO_SUBVTT_INDEX, BINFO_VPTR_INDEX, BINFO_PRIMARY_BASE_OF): New.
(struct tree_binfo): Turn base_binfos into a trailing
VEC(tree). Add vtt_subvtt, vtt_vptr, primary fields.
(binfo_lang_slots): Remove.
* tree.c (binfo_lang_slots): Remove.
(make_tree_binfo_stat): Take a base binfo count, not a
lang slot count. Adjust.
* Makefile.in (TREE_H): Add vec.h
* alias.c (record_component_aliases): Adjust BINFO access.
* dbxout.c (dbxout_type): Likewise.
* dwarf2out.c (gen_member_die): Likewise.
* sdbout.c (sdbout_one_type): Likewise.
* tree-dump.c (deque_and_dump): Likewise.
* config/i386/i386.c (classify_argument,
contains_128bit_aligned_vector_p): Likewise.
* config/sh/symbian.c (symbian_export_vtable_and_rtti_p): Likewise.
* doc/c-tree.texi (Classes): Update BINFO documentation.
cp:
* cp-tree.h (DEF_VEC_P(tree)): Remove here.
(BINFO_SUBVTT_INDEX, BINFO_VPTR_INDEX, BINFO_PRIMARY_BASE_OF):
Moved to common.
(BINFO_LANG_SLOTS): Remove.
* tree.c (copy_binfo): Adjust BINFO creation and accessors.
* decl.c (xref_basetypes): Adjust BINFO creation and accessors.
* class.c (check_bases): Adjust BINFO accessors.
(determine_primary_base, finish_struct_bits,
maybe_warn_about_overly_private_class, warn_hidden,
walk_subobject_offsets, propagate_binfo_offsets, end_of_class,
warn_about_ambiguous_bases, get_vfield_name,
dump_class_hierarchy_r, build_vtt_inits, accumulate_vtbl_inits,
add_vcall_offset_vtbl_entries_r): Likewise.
* dump.c (cp_dump_tree): Likewise.
* init.c (sort_mem_initializers, expand_member_init, build_delete,
push_base_cleanups): Likewise.
* method.c (do_build_copy_constructor, do_build_assign_ref,
synthesize_exception_spec): Likewise.
name-lookup.c (arg_assoc_class): Likewise.
* pt.c (instantiate_class_template,
get_template_base_recursive): Likewise.
* rtti.c (get_pseudo_ti_init, get_pseudo_ti_desc): Likewise.
* typeck2.c (process_init_constructor): Likewise.
* search.c (lookup_base_r, dynamic_cast_base_recurse,
dfs_access_in_type, dfs_walk_real, look_for_overrides,
types_overlap_p, copied_binfo, original_binfo): Likewise.
(binfo_for_vtable): Remove
java:
* class.c (add_interface_do): Remove.
(set_super_info, interface_of_p, maybe_add_interface,
add_interface, make_class_data, layout_class,
add_miranda_methods): Adjust BINFO accessors and addition.
* expr.c (can_widen_reference_to, lookup_field): Adjust BINFO
accessors.
* jcf-write.c (generate_classfile): Likewise.
* parse.y (patch_anonymous_class, check_inner_circular_reference,
check_circular_reference, java_complete_class,
check_abstract_method_definitions,
java_check_abstract_method_definitions,
check_interface_throws_clauses, java_check_abstract_methods,
lookup_java_interface_method2,
find_applicable_accessible_methods_list): Adjust BINFO accessors
and addition.
* typeck.c (find_method_in_interfaces): Adjust BINFO accessors.
From-SVN: r84949
|
|
PR c++/16583
* dump.c (cp_dump_tree): Don't dump the bases if there's no
binfo.
From-SVN: r84812
|
|
* tree.h (TYPE_BINFO_OFFSET, TYPE_BINFO_VTABLE,
TYPE_BINFO_VIRTUALS, TYPE_BINFO_BASETYPES,
TYPE_BINFO_BASETYPE): Remove.
(BINFO_BASETYPES, BINFO_N_BASETYPES, BINFO_BASETYPE): Rename
to ...
(BINFO_BASE_BINFOS, BINFO_N_BASE_BINFOS, BINFO_BASE_BINFO): ...
here.
(BINFO_BASEACCESSES, BINFO_BASEACCESS): Rename to ...
(BINFO_BASE_ACCESSES, BINFO_BASE_ACCESS): ... here.
(BINFO_INHERITANCE_CHAIN): Redocument as it is actually used.
(struct tree_binfo): Rename base_types to base_binfos.
* alias.c (record_component_aliases): Adjust BINFO macros.
* dbxout.c (dbxout_type): Likewise.
* dwarf2out.c (gen_member_die): Likewise.
* sdbout.c (sdbout_one_type): Likewise.
* tree-dump.c (deque_and_dump): Likewise.
* config/i386/i386.c (classify_argument,
contains_128bit_aligned_vector_p): Likewise.
* cp/cp-tree.h (CLASSTYPE_N_BASECLASSES): Remove.
* cp/class.c (build_primary_vtable, check_bases,
determine_primary_base, finish_struct_bits,
maybe_warn_about_overly_private_class, dfs_find_final_overrider_q,
get_basefndecls, warn_hidden, walk_subobject_offsets,
build_base_fields, create_vtable_ptr, propagate_binfo_offsets,
layout_virtual_bases, end_of_class, warn_about_ambiguous_bases,
finish_struct_1, get_vfield_name, contains_empty_class_p,
dump_class_hierarchy_r, finish_vtbls, build_vtt_inits,
dfs_ctor_vtable_bases_queue_p, accumulate_vtbl_inits,
add_vcall_offset_vtbl_entries_r, cp_fold_obj_type_ref): Adjust
BINFO macros.
* cp/decl.c (xref_basetypes): Likewise.
* cp/dump.c (cp_dump_tree): Likewise.
* cp/error.c (dump_expr): Likewise.
* cp/init.c (sort_mem_initializers, expand_member_init,
push_base_cleanups): Likewise.
* cp/method.c (do_build_copy_constructor, do_build_assign_reg,
synthesize_exception_spec): Likewise.
* cp/name-lookup.c (arg_assoc_class):
* cp/pt.c (instantiate_class_template, tsubst,
get_template_base_recursive):
* cp/ptree.c (cxx_print_type):
* cp/rtti.c (get_psuedo_ti_init, get_pseudo_ti_desc): Likewise.
* cp/search.c (lookup_base_r, dynamic_cast_base_recurse,
dfs_access_in_type, access_in_type, lookup_field_queue_p,
bfs_walk, dfs_walk_real, look_for_overrides, markedp, unmarkedp,
marked_pushdecls_p, unmarked_pushdecls_p, dfs_debug_markedp,
dfs_debug_unmarkedp, dfs_check_overlap, dfs_no_overlap_yet,
binfo_for_vtable, copied_binfo, original_binfo): Likewise
* cp/tree.c (copy_base_binfos, make_binfo): Likewise.
* cp/typeck.c (commmon_base_type): Likewise
* cp/typeck2.c (process_init_constructor): Likewise
* java/java-tree.h (CLASSTYPE_SPUER): Adjust BINFO macros.
(TYPE_NVIRTUALS, TYPE_VTABLE): Likewise.
* java/class.c (set_super_info, class_depth, interface_of_p,
maybe_add_interface, add_interface, make_class_data,
layout_class, add_miranda_methods): Adjust BINFO macros.
* java/expr.c (can_widen_reference_to, lookup_field): Likewise.
* java/jcf-write.c (generate_classfile): Likewise.
* java/parse.y (patch_anonymous_class,
check_inner_circular_reference, check_circular_reference,
java_complete_class, check_abstract_method_definitions,
java_check_abstract_method_definitions,
check_interface_throws_clauses, java_check_abstract_methods,
lookup_java_interface_method2,
find_applicable_accessible_methods_list): Likewise.
* java/typeck.c (find_method_in_interface): Likewise.
* java/verify.c (merge_types): Likewise.
From-SVN: r84198
|
|
* tree.h (TREE_VIA_VIRTUAL): Rename to ...
(BINFO_VIRTUAL_P): ... here. Require TREE_BINFO only.
(BINFO_MARKED, BINFO_FLAG_[16]): New binfo flags.
* dbxout.c (dbxout_type): Use BINFO_VIRTUAL_P.
* dwarf2out.c (add_data_member_location_attribute): Likewise.
(gen_inheritance_die): Likewise.
* tree-dump.c (deque_and_dump): Likewise.
* doc/c-tree.texi (Binfos): Add under reconstruction note.
* cp/cp-tree.h (BINFO_MARKED): Remove.
(BINFO_VTABLE_PATH_MARKED, BINFO_NEW_VTABLE_MARKED,
BINFO_DEPENDENT_BASE_P, BINFO_LOST_PRIMARY_P,
BINFO_INDIRECT_PRIMARY_P): Use appropriate BINFO_FLAG_n.
(SET_BINFO_NEW_VTABLE_MARKED): Use BINFO_VIRTUAL_P.
* cp/class.c (build_base_path): Use BINFO_VIRTUAL_P.
(mark_primary_bases, determine_primary_base, base_derived_from,
dfs_find_final_overrider, dfs_find_final_overrider_q,
dfs_find_inal_overrider_post, update_vtable_entry_for_fn,
dfs_modify_vtables, walk_subobject_offsets,
layout_nonempty_base_or_field, build_base_field,
build_base_fields, propagate_binfo_offsets, layout_virtual_bases,
end_of_class, get_vfield_name, dump_class_hierarchy, dump_vtable,
finish_vtbls, build_vtt_inits, dfs_build_secondary_vptr_vtt_inits,
build_ctor_vtbl_group, accumulate_vtble_inits,
dfs_accumulate_vtbls_inits, build_vbase_offset_vtbl_entries,
build_vcall_offset_vtbl_entries, add_vcall_offset_vtbl_entries_r,
add_vcall_offset_vtbl_entries_1): Likewise.
* cp/decl.c (xref_basetypes): Incomming virtual base indicated by
TREE_TYPE. Adjust.
* cp/dump.c (cp_dump_tree): Use BINFO_VIRTUAL_P.
* cp/init.c (finish_init_stmts, sort_mem_initializers,
emit_mem_initializers, build_vtble_address, expand_member_init,
push_base_cleanups): Likewise.
* cp/method.c (do_build_copy_constructor): Likewise.
* cp/pt.c (instantiate_class_template,
get_template_base_recursive): Likewise.
* cp/rtti.c (dfs_class_hint_mark, get_pseudo_ti_init,
get_pseudo_ti_desc): Likewise.
* cp/search.c (lookup_base_r, dynamic_cast_base_recurse,
binfo_from_vbase, binfo_via_virtual, copied_binfo,
original_binfo): Likewise.
* cp/semantics.c (finish_base_specifier): Virtualness is indicated
by TREE_TYPE.
* cp/tree.c (copy_base_binfos): Use BINFO_VIRTUAL_P.
* java/java-tree.h (CLASS_HAS_SUPER_FLAG): Use BINFO_FLAG_1.
* java/class.c (add_interface_do): Use BINFO_VIRTUAL_P.
From-SVN: r84148
|
|
* c-common.def (RETURN_STMT): Remove.
* c-common.h (RETURN_STMT_EXPR): Remove.
(c_expand_return, build_return_stmt): Remove.
(c_common_stmt_codes): Remove RETURN_STMT.
* c-dump.c (dump_next_stmt): Remove.
(c_dump_tree): Remove RETURN_STMT.
* c-decl.c (finish_function): Use c_finish_return.
* c-parse.in (stmt): Likewise.
* c-gimplify.c (gimplify_return_stmt): Remove.
(c_gimplify_expr): Remove RETURN_STMT.
* c-pretty-print.c (pp_c_statement): Likewise.
* c-semantics.c (build_return_stmt): Remove.
* c-tree.h (c_finish_return): Declare.
* c-typeck.c (c_finish_return): Rename from c_expand_return.
Return void. Build RETURN_EXPR directly.
* tree-dump.h (dump_next_stmt): Remove.
cp/
* dump.c (cp_dump_tree): Don't use dump_next_stmt.
* parser.c (cp_parser_jump_statement): Update commentary.
* pt.c (tsubst_expr): Use RETURN_EXPR.
* semantics.c (finish_return_stmt): Likewise.
(finalize_nrv_r): Likewise.
* typeck.c, typeck2.c: Update file start commentary.
From-SVN: r83461
|
|
* c-common.def (IF_STMT, CLEANUP_STMT): Move to cp-tree.def.
* c-common.h (IF_COND, THEN_CLAUSE, ELSE_CLAUSE, CLEANUP_BODY,
CLEANUP_EXPR, CLEANUP_DECL): Move to cp-tree.h.
(c_common_stmt_codes): Remove IF_STMT, CLEANUP_STMT.
* c-dump.c (c_dump_tree): Move IF_STMT, CLEANUP_STMT to cp_dump_tree.
* c-pretty-print.c (pp_c_statement): Similarly.
* c-gimplify.c (gimplify_cleanup_stmt, gimplify_cleanup_stmts,
gimplify_if_stmt): Move to cp-gimplify.c.
(c_genericize, c_gimplify_expr): Don't call them.
* c-semantics.c (push_cleanup): Move to cp/semantics.c.
* c-typeck.c (push_cleanup): New.
(c_begin_if_stmt, c_finish_if_cond, c_finish_then, c_finish_else,
c_finish_if_stmt): Use COND_EXPR.
* tree.h (CLEANUP_EH_ONLY): Update documentation.
cp/
* cp-tree.def (CLEANUP_STMT, IF_STMT): Move from c-common.def.
* cp-gimplify.c (gimplify_if_stmt): Move from c-gimplify.c.
(cp_gimplify_expr): Call it.
(gimplify_cleanup_stmt): Move from c-gimplify.c.
(cp_genericize): New.
* decl.c (finish_function): Call it.
* cp-tree.h (cp_stmt_codes): Add CLEANUP_STMT, IF_STMT.
(CLEANUP_BODY, CLEANUP_EXPR, CLEANUP_DECL): Move from c-common.h.
(IF_COND, THEN_CLAUSE, ELSE_CLAUSE): Likewise.
(cp_genericize): Declare.
* cxx-pretty-print.c (pp_cxx_statement): Add CLEANUP_STMT, IF_STMT.
* dump.c (cp_dump_tree): Likewise.
* semantics.c (push_cleanup): Move from c-semantics.c.
From-SVN: r83407
|
|
* cp-tree.h: Don't declare anonymous_namespace_name.
* decl.c: Don't define it.
* dump.c (cp_dump_tree): Don't check for it.
* cxx-pretty-print.c (pp_cxx_original_namespace_definition): Likewise.
* error.c (dump_decl): Likewise.
* name-lookup.c: Define it here.
(push_namespace): Put it in DECL_ASSEMBLER_NAME instead.
* mangle.c (write_unqualified_name): Adjust.
From-SVN: r74433
|
|
* fold-const.c (force_fit_type): Handle OFFSET_TYPE.
* varasam.c (output_constant): Likewise.
2003-07-22 Mark Mitchell <mark@codesourcery.com>
Eliminate use of POINTER_TYPE for pointers-to-members.
* call.c (standard_conversion): Rework pointer-to-member handling.
Add comments.
(add_builtin_candidate): Likewise.
(resolve_scoped_fn_name): Remove.
(build_conditional_expr): Rework pointer-to-member handling.
(compare_ics): Likewise.
* class.c (check_field_decls): Use TYPE_PTR_P.
* cp-lang.c (cp_var_mod_type_p): Rework pointer-to-member
handling.
* cp-tree.h (SCALAR_TYPE_P): Use TYPE_PTR_TO_MEMBER_P.
(TYPE_PTRMEM_P): Add comment.
(TYPE_PTR_P): Simplify.
(TYPE_PTROB_P): Correct definition.
(TYPE_PTR_TO_MEMBER_P): New macro.
(TYPE_PTRMEM_CLASS_TYPE): Adjust.
(TYPE_PTRMEM_POINTED_TO_TYPE): Likewise.
(resolved_scoped_fn_name): Remove declaration.
(build_offset_ref): Change prototype.
(resolve_offset_ref): Remove.
(comp_target_types): Remove.
* cvt.c (cp_convert_to_pointer): Rework pointer-to-member
handling.
(convert_to_reference): Use can_convert.
(ocp_convert): Improve error handling. Rework pointer-to-member
handling.
(perform_qualification_conversions): Rework pointer-to-member
handling.
* decl.c (build_ptrmem_type): Handle functions too.
(create_array_type_for_decl): Remove OFFSET_TYPE error message.
(grokdeclarator): Use OFFSET_TYPE for pointers to data members.
(grokparms): Remove OFFSET_TYPE error message.
* dump.c (cp_dump_tree): Rework pointer-to-member handling.
* error.c (dump_type_prefix): Likewise.
* expr.c (cplus_expand_constant): Use build_nop.
* init.c (build_offset_ref): Add address_p parameter. Fold in
necessary bits from resolve_offset_ref.
(resolve_offset_ref): Remove.
* parser.c (cp_parser_postfix_expression): Remove special case
code for OFFSET_TYPE.
* pt.c (convert_nontype_argument): Rework pointer-to-member
handling.
(convert_template_argument): Likewise.
(unify): Likewise.
(invalid_nontype_parm_type_p): Likewise.
(dependent_type_p_r): Likewise.
* rtti.c (get_tinfo_decl): Remove OFFSET_TYPE special case.
(target_incomplete_p_): Rework pointer-to-member
handling.
(get_pseudo_ti_init): Likewise.
(get_pseudo_ti_desc): Likewise.
* semantics.c (finish_qualified_id_expr): Adjust call to
build_offset_ref. Remove use of resolve_offset_ref.
* tree.c (pod_type_p): Use TYPE_PTR_TO_MEMBER_P.
* typeck.c (target_type): Use TYPE_PTRMEM_P.
(type_unknown_p): Remove obsolete code about the time before
non-dependent expressions were handled correctly.
(qualify_type_recursive): Remove.
(composite_pointer_type_r): New function.
(composite_pointer_type): Use it.
(merge_types): Remove dead comments.
(comp_cv_target_types): Remove.
(comp_target_types): Likewise.
(comp_target_parms): Likewise.
(cxx_sizeof_or_alignof_type): Remove OFFSET_TYPE error.
(build_indirect_ref): Use TYPE_PTR_TO_MEMBER_P.
(build_binary_op): Do not use of comp_target_types.
(pointer_diff): Remove OFFSET_TYPE case.
(build_unary_op): Adjust pointer-to-member handling.
(unary_complex_lvalue): Likewise.
(check_for_casting_away_constness): Add description parameter.
(build_static_cast): Pass it.
(build_reinterpret_cast): Use check_for_casting_away_constness.
(build_const_cast): Adjust pointer-to-member handling.
(build_c_cast): Likewise.
(convert_for_assignment): Remove OFFSET_TYPE error message.
(comp_ptr_ttypes_real): Adjust pointer-to-member handling.
(comp_ptr_ttypes_reinterpret): Remove.
(casts_away_constness_r): Adjust pointer-to-member handling.
(casts_away_constness): Liekwise.
(strip_all_pointer_quals): Remove.
* typeck2.c (digest_init): Adjust pointer-to-member handling.
(build_m_component_ref): Likewise.
From-SVN: r69691
|
|
* cp-tree.h (language_to_string): Adjust declaration.
* dump.c (cp_dump_tree): Adjust usage.
* error.c (dump_char): Use output_formatted_scalar. Tidy.
(parm_to_string): Lose unused parameter. Tidy.
(expr_to_string): Likewise.
(code_to_string): Likewise.
(language_to_string): Likewise.
(op_to_string): Likewise.
(assop_to_string): Likewise.
(digit_buffer): Remove.
(dump_type): Format builtin vector type as __vector__.
From-SVN: r68668
|
|
(gcc)
* c-common.h (c_dump_tree), c-dump.c (c_dump_tree),
langhooks-def.h (lhd_tree_dump_dump_tree),
langhooks.c (lhd_tree_dump_dump_tree), langhooks.h (*dump_tree):
Change return type from 'int' to 'bool'. Replace 0 and 1 with
true and false in return statements.
(cp)
* dump.c (cp_dump_tree), cp-tree.h (cp_dump_tree): Change return
type from 'int' to 'bool'. Replace 0 and 1 with true and false in
return statements.
(java)
* lang.c (java_dump_tree): Change return type from 'int' to 'bool'.
Replace 0 and 1 with true and false in return statements.
From-SVN: r64596
|
|
From-SVN: r61691
|
|
* fold-const.c (fold) [COND_EXPR]: Avoid NOP_EXPRs better.
* integrate.c (copy_decl_for_inlining): Don't clear the rtl for
static/external decls.
cp/
* call.c (build_conditional_expr): Stabilize lvalues properly.
* cvt.c (ocp_convert): Don't build NOP_EXPRs of class type.
* tree.c (lvalue_p_1): Don't allow sloppy NOP_EXPRs as lvalues.
Don't allow CALL_EXPR or VA_ARG_EXPR, either.
* call.c (convert_like_real): Call decl_constant_value for an
IDENTITY_CONV even if there are no more conversions.
* cvt.c (build_up_reference): Don't push unnamed temps.
* decl2.c (do_namespace_alias): Namespace aliases are DECL_EXTERNAL.
* dump.c (cp_dump_tree): Don't try to dump class-specific fields
for a backend struct.
* except.c (wrap_cleanups_r, build_throw): Make
MUST_NOT_THROW_EXPRs void.
* init.c (expand_default_init): Update to handle MUST_NOT_THROW_EXPR.
* init.c (build_vec_delete_1): Pre-evaluate the base address.
* init.c (get_temp_regvar): Simplify logic.
* tree.c (cp_copy_res_decl_for_inlining): Only do debug tweaks if
our replacement is a decl.
From-SVN: r60851
|
|
* call.c, class.c, cp-lang.c, cp-tree.h, cvt.c, dump.c, error.c,
except.c, expr.c friend.c, g++spec.c, init.c, lang-options.h,
lang-specs.h, lex.c, mangle.c, method.c, optimize.c, parser.c,
pt.c, ptree.c, repo.c, rtti.c, search.c, semantics.c, tree.c,
typeck.c, typeck2.c: Replace "GNU CC" with "GCC" in the
copyright header.
* lex.h: parse.y is dead, so don't mention it. Also replace the
copyright header with the default GNU copyright header.
From-SVN: r60738
|
|
cp:
* cp-tree.h (THUNK_TARGET): New macro.
(THUNK_VIRTUAL_OFFSET): For result thunks it is always a binfo.
(finish_thunk): Remove offset parms.
* class.c (find_final_overrider): Look through thunks.
(get_vcall_index): Use THUNK_TARGET.
(update_vtable_entry_for_fn): Look through thunks. Set covariant
fixed offset here. Adjust finish_thunk call.
(build_vtbl_initializer): Adjust finish_thunk calls.
* mangle.c (mangle_call_offset): Remove superfluous if.
(mangle_thunk): Adjust.
* method.c (make_thunk): Adjust.
(finish_thunk): Adjust.
(thunk_adjust): Remove assert.
(use_thunk): Use THUNK_TARGET
* dump1.c (cp_dump_tree): Adjust thunk dumping.
testsuite:
* g++.dg/inherit/covariant5.C: New test.
* g++.dg/inherit/covariant6.C: New test.
* g++.dg/inherit/covariant7.C: New test.
From-SVN: r60628
|
|
PR c++/9054
* class.c (layout_class_type): Set DECL_CONTEXT of type for base.
* dump.c (cp_dump_tree, RECORD_TYPE): Deal with type for base types.
From-SVN: r60627
|
|
From-SVN: r60174
|
|
* cp-tree.h (lang_decl_flags): Remove init_priority.
(lang_decl): Add delta.
(GLOBAL_INIT_PRIORITY): Remove.
(THUNK_DELTA): Revise definition.
* decl2.c (start_objects): Don't set GLOBAL_INIT_PRIORITY.
* dump.c (cp_dump_tree): Don't dump it.
From-SVN: r58680
|
|
* c-dump.c: Resurrect.
* tree-dump.c: Move C-specific stuff to c-dump.c.
* c-common.h: Declare c_dump_tree.
* c-lang.c (LANG_HOOKS_TREE_DUMP_DUMP_TREE_FN): Define.
* Makefile.in (C_AND_OBJC_OBJS): Add c-dump.o.
(c-dump.o): New rule.
cp/
* dump.c (cp_dump_tree): Call c_dump_tree.
* Make-lang.in (CXX_C_OBJS): Add c-dump.o.
From-SVN: r55776
|
|
parameter will not call local variable destructors if exception is thrown.)
PR c++/5636
* tree.h (CLEANUP_EH_ONLY): New macro.
* stmt.c (expand_decl_cleanup_eh): New fn.
(expand_cleanups): Check CLEANUP_EH_ONLY.
* c-semantics.c (genrtl_decl_cleanup): Just take the CLEANUP_STMT.
Use expand_decl_cleanup_eh.
(expand_stmt): Adjust.
* c-common.h: Adjust prototype.
* cp/semantics.c (nullify_returns_r): Just set CLEANUP_EH_ONLY on
cleanup for nrv.
* except.c (struct eh_status): Remove protect_list.
(begin_protect_partials, end_protect_partials): Remove.
(add_partial_entry): Remove.
* except.h: Remove prototypes.
* expr.c (expand_expr) [WITH_CLEANUP_EXPR, TARGET_EXPR]: Use
expand_decl_cleanup_eh.
cp/:
* semantics.c (finish_eh_cleanup): New fn.
* cp-tree.h: Add prototype.
* init.c (perform_member_init, expand_cleanup_for_base): Use
finish_eh_cleanup.
* cp-tree.def (SUBOBJECT, CTOR_STMT): Remove.
* cp-tree.h: Remove references.
* decl.c (begin_constructor_body, end_constructor_body): Likewise.
* dump.c (cp_dump_tree): Likewise.
* pt.c (tsubst_expr): Likewise.
* semantics.c (genrtl_ctor_stmt, genrtl_subobject): Remove.
(cp_expand_stmt): Remove handling of CTOR_STMT and SUBOBJECT.
* tree.c (cp_statement_code_p): Likewise.
* init.c (build_new_1): Set CLEANUP_EH_ONLY on deleting cleanup.
From-SVN: r51827
|
|
* c-common.c (statement_code_p): Handle CLEANUP_STMT.
* c-common.def (CLEANUP_STMT): New tree node.
* c-common.h (CLEANUP_DECL): New macro.
(CLEANUP_EXPR): Likewise.
* c-semantics.c (expand_stmt): Handle CLEANUP_STMT.
* tree-dump.c (dequeue_and_dump): Handle CLEANUP_STMT.
* tree-inline.c (initialize_inlined_parameters): Clean up
new local variables.
* cp-tree.h (CLEANUP_DECL): Remove.
(CLEANUP_EXPR): Likewise.
* decl.c (destroy_local_var): Simplify.
(maybe_build_cleanup): Tidy.
* dump.c (cp_dump_tree): Remove handling of CLEANUP_STMT.
* semantics.c (cp_expand_stmt): Likewise.
* cp/tree.c (cp_statement_code_p): Likewise.
* g++.dg/opt/dtor1.C: New test.
From-SVN: r50830
|
|
* tree-dump.c: Rename from c-dump.c. Include c-tree.h, not c-common.h.
(lang_type_quals): Declare.
(dequeue_and_dump): Use lang_hooks.tree_dump.type_quals function to
retrieve language-specific qualifiers for a type node, instead of
C_TYPE_QUALS. Likewise for lang_hooks.tree_dump.dump_tree instead of
lang_dump_tree.
* tree-dump.h: Rename from c-dump.h.
* c-common.h (C_TYPE_QUALS): Removed.
Move declarations for tree-dump.c interface to...
* tree.h: ... here. Remove lang_dump_tree.
* langhooks.h (struct lang_hooks_for_tree_dump): New.
(struct lang_hooks): Add tree_dump hooks.
* langhooks.c (lhd_tree_dump_dump_tree): New function.
(lhd_tree_dump_type_quals): New function.
* langhooks-def.h (lhd_tree_dump_dump_tree, lhd_tree_dump_type_quals):
Declare.
(LANG_HOOKS_INITIALIZER): Add tree_dump hooks.
* Makefile.in: Move tree-dump.o to language-independent back-end.
cp:
* cp-tree.h (CP_TYPE_QUALS): Removed.
* decl.c (cxx_init_decl_processing): Don't set lang_dump_tree.
* cp-lang.c: Set LANG_HOOKS_TREE_DUMP_DUMP_TREE_FN and
LANG_HOOKS_TREE_DUMP_TYPE_QUALS_FN.
* dump.c (cp_dump_tree): Use void* dump_info argument to match
lang-hooks prototype.
* call.c, cp-tree.h, cvt.c, decl.c, init.c, mangle.c, method.c, pt.c,
rtti.c, semantics.c, tree.c, typeck.c, typeck2.c: All references to
CP_TYPE_QUALS changed to cp_type_quals.
* Make-lang.in: References to c-dump.h changed to tree-dump.h.
(CXX_C_OBJS): Remove c-dump.o.
From-SVN: r47257
|
|
argument)
* dump.c (dump_op): New function.
(cp_dump_tree): Dump CLASSTYPE_TEMPLATE_SPECIALIZATION. Use
dump_op. Dump DECL_MUTABLE, access and staticness for VAR_DECLs.
DECL_PURE_VIRTUAL_P, DECL_VIRTUAL_P,
PR4629
* semantics.c (finish_sizeof): Make sure that expression created
while processing a template do not have a type.
(finish_alignof): Likewise.
* typeck.c (c_sizeof): Likewise.
(expr_sizeof): Likewise.
From-SVN: r47201
|
|
.: Kill -fhonor-std.
* doc/c-tree.texi (Namespaces): Remove std & -fhonor-std
interaction.
* doc/invoke.texi (C++ Dialect Options): Remove -fno-honor-std.
cp:
Kill -fhonor-std.
* NEWS: Document.
* cp-tree.h (flag_honor_std): Remove.
(CPTI_FAKE_STD): Remove.
(std_node): Remove comment about it being NULL.
(fake_std_node): Remove.
* decl.c (in_fake_std): Remove.
(walk_namespaces_r): Remove fake_std_node check.
(push_namespace): Remove in_fake_std code.
(pop_namespace): Likewise.
(lookup_name_real): Remove fake_std_node check.
(init_decl_processing): Always create std_node. Always add
std:: things there.
(builtin_function): Always put non '_' fns in std.
* decl2.c (flag_honor_std): Remove.
(lang_f_options): Remove honor-std.
(unsupported_options): Add honor-std.
(set_decl_namespace): Remove fake_std_node check.
(validate_nonmember_using_decl): Likewise.
(do_using_directive): Likewise.
(handle_class_head): Likewise.
* dump.c (cp_dump_tree): Likewise.
* except.c (init_exception_processing): Adjust.
* init.c (build_member_call): Remove fake_std_node check.
(build_offset_ref): Likewise.
* lang-options.h: Remove -fhonor-std, -fno-honor-std.
* rtti.c (init_rtti_processing): Adjust.
testsuite:
Kill -fhonor-std.
* g++.old-deja/g++.ns/ns14.C: Remove special options.
* g++.old-deja/g++.other/std1.C: Likewise.
* g++.old-deja/g++.robertl/eb133.C: Likewise. Add using directive.
From-SVN: r44569
|
|
* c-common.h (flag_dump_translation_unit): Remove.
(enum tree_dump_index): Define.
(TDF_ADDRESS, TDF_SLIM): New #defines.
(dump_node_to_file): Remove.
(dump_node): Make extern. Add flags.
(dump_flag, dump_enabled_p, dump_begin, dump_end,
dump_switch_p): Prototype.
* c-common.c (flag_dump_translation_unit): Remove.
* c-decl.c (c_decode_option): Remove -fdump-translation-unit
logic. Use dump_switch_p.
* c-dump.h (struct dump_info): Add node and user fields.
(dump_pointer): Declare.
* c-dump.c (dump_node): Make extern. Add flags.
(SOL_COLUMN, EOL_COLUMN, COLUMN_ALIGNMENT): New #defines.
(dump_new_line, dump_maybe_newline): Use them.
(dump_pointer): New function.
(dequeue_and_dump): Check TDF_SLIM before dumping a _DECL's
chain or function's body. Dump address, if TDF_ADDRESS set.
(dump_flag): Define.
(dump_node_to_file): Remove.
(struct dump_file_info): New struct.
(dump_files): New array.
(dump_begin, dump_end, dump_enabled_p, dump_switch_p): Define.
* c-lang.c (finish_file): Adjust dumping.
* toplev.h (dump_base_name): Make extern.
* invoke.texi: Document new flags.
cp:
* class.c (maybe_indent_hierarchy): New function.
(dump_class_hierarchy_r): Add flags. Dump extra binfo
information, if enabled. Use maybe_indent_hierarchy. Adjust
output format.
(dump_class_hierarchy): Adjust prototype. Adjust output format.
(dump_array, dump_vtable, dump_vtt): New functions.
(finish_struct_1): Adjust hierarchy dumping.
(initialize_vtable): Call dump_vtable.
(build_vtt): Call dump_vtt.
(build_ctor_vtbl_group): Call dump_vtable.
* decl2.c (flag_dump_class_layout): Remove.
(cxx_decode_option): Remove dump translation unit
and dump class hierarchy check. Call dump_switch_p.
(finish_file): Adjust dumping.
(dump.c): Only dump base classes if not TDF_SLIM.
Only dump namespace members if not TDF_SLIM.
* optimize.c (dump_function): New function.
(optimize_function): Call dump_function.
* semantics.c (expand_body): Use dump_enabled_p.
From-SVN: r42896
|
|
* cp-tree.def (START_CATCH_STMT): Lose.
* dump.c (cp_dump_tree): Don't dump it. Do dump HANDLER_PARMS.
* tree.c (cp_statement_code_p): Don't case it.
* semantics.c (cp_expand_stmt): Likewise.
* except.c (expand_start_catch_block): Don't start any blocks.
Return the type.
(expand_end_catch_block): Don't end any blocks.
* parse.y (handler): Don't pass anything from finish_handler_parms
to finish_handler.
* pt.c (tsubst_expr): Likewise.
* semantics.c (begin_handler): Call note_level_for_catch here.
(finish_handler_parms): Don't return anything.
(genrtl_catch_block, begin_catch_block): Lose.
(genrtl_handler): Call expand_start_catch here.
* cp-tree.h (START_CATCH_TYPE): Lose.
(HANDLER_TYPE): New.
From-SVN: r42388
|
|
* dump.c (cp_dump_tree, USING_STMT case): New case.
* tree.c (cp_statement_code_p): Add USING_STMT.
* decl2.c (do_using_directive): Add the using directive statement.
* tree.c (walk_tree): Reformat an if block.
From-SVN: r41783
|
|
From-SVN: r40924
|
|
* dump.c (dump_access): New function.
(cp_dump_tree): Use it. Dump basetype information for class
types.
Co-Authored-By: Mark Mitchell <mark@codesourcery.com>
From-SVN: r40866
|
|
* c-dump.c (dequeue_and_dump): Dump function bodies.
* dump.c (cp_dump_tree): Don't dump function bodies here.
From-SVN: r37359
|
|
* Makefile.in (C_AND_OBJC_OBJS): Add c-dump.o.
(c-dump.o): New target.
* c-common.h (flag_dump_translation_unit): New variable.
(C_TYPE_QUALS): New macro.
(strip_array_types): New function.
(DECL_C_BIT_FIELD): New macro.
(SET_DECL_C_BIT_FIELD): Likewise.
(CLEAR_DECL_C_BIT_FIELD): Likewise.
(dump_info_p): New typedef.
(dump_tree_fn): Likewise.
(lang_dump_tree): New variable.
(dump_node_to_file): New function.
* c-common.c (flag_dump_translation_unit): Define it.
(strip_array_types): New function.
* c-decl.c (c_decode_option): Handle -fdump-translation-unit.
* c-lang.c (finish_file): Call dump_node_to_file if
flag_dump_translation_unit.
* c-semantics.c (mark_rtl_for_local_static): Fix typo in comment.
* c-tree.h (DECL_C_BIT_FIELD): Remove declaration.
* c-dump.c: New file.
* Make-lang.in (CXX_C_OBJS): Add c-dump.o.
(dump.o): Update dependency list.
* cp-tree.h (DECL_MAYBE_TEMPLATE): Remove.
(flag_dump_translation_unit): Likewise.
(CP_TYPE_QUALS): Adjust definition.
(DECL_C_BIT_FIELD): Remove.
(SET_DECL_C_BIT_FIELD): Likewise.
(CLEAR_DECL_C_BIT_FIELD): Likewise.
(add_maybe_template): Likewise.
(strip_array_types): Likewise.
(dump_node_to_file): Likewise.
(cp_dump_tree): New function.
* decl.c (init_decl_processing): Set lang_dump_tree.
* decl2.c (flag_dump_translation_unit): Remove.
* dump.c: Move most of it to ../c-dump.c.
(cp_dump_tree): New function.
* pt.c (add_maybe_template): Remove.
* typeck.c (strip_array_types): Likewise.
From-SVN: r37358
|
|
process_command, main), gcov.c (open_files, output_data), tlink.c
(frob_extension, scan_linker_output), toplev.c
(file_name_nondirectory): Use strchr () and strrchr () instead of
index () and rindex ().
cp:
* dump.c (dequeue_and_dump), lex.c (interface_strcmp), method.c
(build_overload_value), repo.c (open_repo_file), xref.c
(open_xref_file): Use strchr () and strrchr () instead of index ()
and rindex ().
f:
* com.c (open_include_file, ffecom_open_include_): Use strchr ()
and strrchr () instead of index () and rindex ().
From-SVN: r37206
|
|
* c-common.h (flag_no_builtin): Declare.
(flag_no_nonansi_builtin): Likewise.
(c_common_nodes_and_builtins): Change prototype.
* c-common.c (flag_no_builtin): New variable.
(flag_no_nonansi_builtin): Likewise.
(c_common_nodes_and_builtins): Remove parameters. Adjust
accordingly.
* c-decl.c (flag_no_builtin): Remove.
(flag_no_nonansi_builtin): Likewise.
(init_decl_processing): Adjust call to
c_common_nodes_and_builtins.
* cp-tree.h (cp_tree_index): Add CPTI_FAKE_STD.
(fake_std_node): New macro.
* decl.c (in_std): Rename to ...
(in_fake_std): ... this.
(flag_no_builtin): Remove.
(flag_no_nonansi_builtin): Likewise.
(walk_namespaces_r): Use fake_std_node.
(push_namespace): Use std_identifier.
(pop_namespace): Use in_fake_std.
(lookup_name_real): Use fake_std_node.
(init_decl_processing): When -fhonor-std, create the `std'
namespace. Don't create a dummy fake_std_node in that case.
Adjust call to c_common_nodes_and_builtins. Use std_identifier.
(builtin_function): Put builtins whose names don't begin
with `_' in the std namespace.
* decl2.c (flag_no_builtin): Remove.
(flag_no_nonansi_builtin): Likewise.
(set_decl_namespace): Use fake_std_node.
(validate_nonmember_using_decl): Likewise.
(do_using_directive): Likewise.
(handle_class_head): Likewise.
* dump.c (dequeue_and_dump): Likewise.
* except.c (init_exception_processing): Use std_identifier.
* init.c (build_member_call): Use fake_std_node.
* rtti.c (init_rtti_processing): Use std_identifier.
From-SVN: r36940
|
|
* c-common.c (back_end_hook): New variable.
* c-common.h (back_end_hook): Declare it.
* c-lang.c (finish_file): Use it.
* emit-rtl.c (init_emit_once): Initialize the const_int_htab
earlier.
* cp-tree.h (back_end_hook): Remove declaration.
* decl2.c (back_end_hook): Remove definition.
* dump.c (dequeue_and_dump): Dump TREE_USED.
From-SVN: r36928
|
|
* cp-tree.h (BV_USE_VCALL_INDEX_P): New macro.
(BV_GENERATE_THUNK_WITH_VTABLE_P): Likewise.
(lang_decl_flags): Add generate_with_vtable_p. Make vcall_offset
a tree, not an int.
(THUNK_GENERATE_WITH_VTABLE_P): New macro.
(make_thunk): Change prototype.
(emit_thunk): Rename to use_thunk.
(mangle_thunk): Change prototype.
* class.c (get_derived_offset): Simplify.
(copy_virtuals): Clear BV_USE_VCALL_INDEX_P and
BV_GENERATE_THUNK_WITH_VTABLE_P.
(build_primary_vtable): Simplify.
(add_virtual_function): Use BV_FN, rather than TREE_VALUE.
(dfs_find_base): Remove.
(update_vtable_entry_for_fn): Correct bug in finding the base
where a virtual function was first declared. Figure out whether
or not to emit a vcall-thunk with the vtables in which it appears.
Correct logic for deciding whether to use an ordinary thunk, or a
vcall thunk.
(finish_struct_1): Remove unnecssary code.
(build_vtbl_initializer): Use ssize_int for the running counter of
negative indices.
(build_vtbl_initializer): Only use vcall thunks where necessary.
Mark thunks as needing to be emitted with their vtables, or not.
(build_vbase_offset_vtbl_entries): Adjust for use of ssize_int in
indices. Use size_binop.
(dfs_build_vcall_offset_vtbl_entries): Don't rely on
BINFO_PRIMARY_MARKED_P here. Use BV_FN consistently. Use
size_binop.
(build_rtti_vtbl_entries): Adjust call to build_vtable_entry.
(build_vtable_entry): Mark thunks as needing to be emitted with
their vtables, or not.
* decl.c (lang_mark_tree): Mark the vcall_offset in a thunk.
* decl2.c (mark_vtable_entries): Use use_thunk instead of
emit_thunk.
* dump.c (dequeue_and_dump): Remove dead code. Dump new thunk
information.
* error.c (dump_expr): Use BV_FN.
* mangle.c (mangle_thunk): Adjust now that vcall_offset is a tree,
not an int.
* method.c (make_thunk): Likewise.
(emit_thunk): Rename to use_thunk. Allow callers to decide
whether or not to actually emit the thunk. Adjust for changes in
representation of vcall offsets.
* search.c (dfs_get_pure_virtuals): Use BV_FN.
* semantics.c (emit_associated_thunks): New function.
(expand_body): Use it.
* ir.texi: Adjust decriptions of thunks.
From-SVN: r34656
|
|
x_member_init_list.
* cp-tree.h (struct language_function): Remove x_base_init_list
and x_member_init_list.
(current_base_init_list): Remove.
(current_member_init_list): Likewise.
(setup_vtbl_ptr): Change prototype.
(emit_base_init): Likewise.
(expand_member_init): Likewise.
(reinit_parse_for_function): Remove.
* decl.c (save_function_data): Don't clear x_base_init_list and
x_member_init_list.
(mark_language_function): Don't mark them.
* init.c (perform_member_init): Tweak comment.
(sort_member_init): Take the list of initializers as an argument.
(sort_base_init): Likewise.
(emit_base_init): Likewise.
(expand_member_init): Return the initializer. Don't use global
variables.
* lex.c (reinit_parse_for_function): Remove.
* method.c (build_template_parm_names): Correct substitution.
(do_build_copy_constructor): Don't use current_member_init_list
and current_base_init_list.
(synthesize_method): Likewise.
* parse.y (base_init): Split mem-initializers into
base-initializers and field-initializers.
(member_init_list): Build up the list here.
(member_init): Return the initializer.
(fn.depfn): Don't use reinit_parse_for_function.
* parse.c: Regenerated.
* pt.c (convert_nontype_argument): Don't make an ADDR_EXPR of the
ERROR_MARK.
(tsubst_expr): Don't use current_member_init_list
and current_base_init_list.
(tsubst_expr_values): Rename to ...
(tsubst_initializer_list): ... this. Use convert_from_reference.
* semantics.c (setup_vtbl_ptr): Don't use current_member_init_list
and current_base_init_list.
(begin_function_definition): Don't call reinit_parse_for_function.
* dump.c (dequeue_and_dump): Use TREE_VEC_LENGTH with vectors.
* error.c (dump_expr): Handle ADDR_EXPRs with REFERENCE_TYPE
correctly.
From-SVN: r34571
|
|
* cp-tree.h (TMPL_ARGS_LEVEL): Clarify comment.
(INNERMOST_TEMPLATE_ARGS): New macro.
(innermost_args): Remove.
(get_innermost_template_args): New function.
* decl2.c (arg_assoc_class): Use INNERMOST_TEMPLATE_ARGS.
* error.c (dump_function_decl): Be caution when using
most_general_template.
* method.c (build_template_parm_names): Use
INNERMOST_TEMPLATE_ARGS.
* pt.c (add_to_template_args): Tidy comment
(get_innermost_template_args): New function.
(check_explicit_specialization): Clear DECL_INITIAL for a new
specialization.
(process_partial_specialization): Use INNERMOST_TEMPLATE_ARGS.
Tidy.
(push_template_decl): Always register specializations of the most
general template.
(convert_template_argument): Use INNERMOST_TEMPLATE_ARGS.
(coerce_template_parms): Likewise.
(lookup_template_class): Likewise.
(innermost_args): Remove.
(tsubst_decl): Use INNERMOST_TEMPLATE_ARGS.
(tsubst_decl): Handle tricky specializations. Use
get_innermost_template_args.
(instantiate_template): Simplify handling of partial
instantiations.
(get_class_bindings): Use INNERMOST_TEMPLATE_ARGS.
(most_general_template): Reimplement, in a more straightforward
manner.
(regenerate_decl_from_template): Tweak formatting. Use
TMPL_ARGS_DEPTH for clarity.
(set_mangled_name_for_template_decl): Use INNERMOST_ARGS.
* dump.c (dequeue_and_dump): Dump information about thunks.
From-SVN: r34384
|
|
* cp-tree.h (IDENTIFIER_TYPENAME_P): Use a flag, not strncmp.
(DECL_CONV_FN_P): Simplify.
(DECL_OPERATOR): Remove.
(language_to_string): Declare.
* decl.c (duplicate_decls): Fix typo in comment.
(grokdeclarator): Adjust use of IDENTIFIER_TYPENAME_P.
(grok_op_properties): Use DECL_CONV_FN_P instead of
IDENTIFIER_TYPENAME_P.
* dump.c (dequeue_and_dump): Dump the language linkage of
declarations.
* error.c (language_to_string): Give it external linkage.
* method.c (build_typename_overload): Set IDENTIFIER_TYPENAME_P.
(implicitly_declare_fn): Set DECL_LANGUAGE.
* pt.c (check_explicit_specialization): Use DECL_CONV_FN_P, not
IDENTIFIER_TYPENAME_P.
(tsubst_decl): Likewise.
(tsubst_copy): Adjust use of IDENTIFIER_TYPENAME_P.
* semantics.c (finish_member_declaration): Don't mark members of
classes declared in an extern "C" region as extern "C".
From-SVN: r34095
|
|
* cp-tree.def (THUNK_DECL): Remove.
* cp-tree.h (DECL_THUNK_P): New macro.
(DECL_NON_THUNK_FUNCTION_P): Likewise.
(DECL_EXTERN_C_FUNCTION_P): Likewise.
(SET_DECL_THUNK_P): Likewise.
(DELTA_FROM_VTABLE_ENTRY): Use DECL_THUNK_P.
(FNADDR_FROM_VTABLE_ENTRY): Likewise.
(DECL_MAIN_P): Use DECL_EXTERN_C_FUNCTION_P.
* decl.c (decls_match): Use DECL_EXTERN_C_P.
(duplicate_decls): Likewise.
(pushdecl): Likewise. Adjust thunk handling.
(grokfndecl): Use DECL_EXTERN_C_P.
* decl2.c (mark_vtable_entries): Use DECL_THUNK_P.
* dump.c (dequeue_and_dump): Remove THUNK_DECL handling.
* except.c (nothrow_libfn_p): Use DECL_EXTERN_C_P.
* expr.c (cplus_expand_expr): Remove THUNK_DECL handling.
* method.c (make_thunk): Use SET_DECL_THUNK_P. Set
DECL_NO_STATIC_CHAIN.
(emit_thunk): Don't play games with TREE_CODE on thunks. Don't
set DECL_DESTRUCTOR_P or DECL_CONSTRUCTOR_P on a thunk.
* search.c (covariant_return_p): Remove THUNK_DECL handling.
* ir.texi: Update.
From-SVN: r33647
|
|
* cp-tree.h (cp_tree_index): Add CPTI_DTOR_IDENTIFIER.
(complete_dtor_identifier): New macro.
(CLASSTYPE_FIRST_CONVERSION): Remove.
(CLASSTYPE_CONSTRUCTOR_SLOT): New macro.
(CLASSTYPE_DESTRUCTOR_SLOT): Likewise.
(CLASSTYPE_FIRST_CONVERSION_SLOT): Likewise.
(CLASSTYPE_CONSTRUCTORS): Likewise.
(CLASSTYPE_DESTRUCTORS): Likewise.
(lang_decl): Add cloned_function.
(DECL_COMPLETE_CONSTRUCTOR_P): New macro.
(DECL_BASE_CONSTRUCTOR_P): Likewise.
(DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P): Likewise.
(DECL_MAYBE_IN_CHARGE_DESTRUCTOR_P): Likewise.
(DECL_CLONED_FUNCTION_P): Likewise.
(DECL_CLONED_FUNCTION): Likewise.
(clone_function_decl): Declare.
(maybe_clone_body): Likewise.
* call.c (build_user_type_conversion_1): Call complete object
constructors in the new ABI.
(build_new_method_call): Don't add in-charge parameters under the
new ABI.
* class.c (add_method): Use DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P,
DECL_MAYBE_IN_CHARGE_DESTRUCTOR_P, CLASSTYPE_CONSTRUCTOR_SLOT, and
CLASSTYPE_DESTRUCTOR_SLOT.
(build_clone): New function.
(clone_function_decl): Likewise.
(clone_constructors_and_destructors): Likewise.
(check_bases_and_members): Use it.
* decl.c (iniitialize_predefined_identifiers): Initialize
complete_dtor_identifier.
(finish_function): Don't add extra code to a clone.
(lang_mark_tree): Mark cloned_function.
* decl2.c (mark_used): Don't bother trying to instantiate things
we synthesized.
* dump.c (dequeue_and_dump): Don't dump CP_DECL_CONTEXT twice.
* method.c (set_mangled_name_for_decl): Don't treat clones as
constructors.
(synthesize_method): Sythesize cloned functions, not the clones.
* optimize.c (inline_data): Update comment on ret_label.
(remap_block): Don't assume DECL_INITIAL exists.
(copy_body_r): Allow ret_label to be NULL.
(maybe_clone_body): Define.
* pt.c (tsubst_decl): Handle clones.
(instantiate_clone): New function.
(instantiate_template): Use it.
(set_mangled_name_for_template_decl): Don't treat clones as
constructors.
* search.c (lookup_fnfields_1): Use CLASSTYPE_CONSTRUCTOR_SLOT,
CLASSTYPE_DESTRUCTOR_SLOT, and CLASSTYPE_FIRST_CONVERSION_SLOT.
* semantics.c (expand_body): Clone function bodies as necessary.
From-SVN: r33084
|