aboutsummaryrefslogtreecommitdiff
path: root/gcc/except.h
AgeCommit message (Collapse)AuthorFilesLines
2007-08-27alias.c (memory_modified_1, [...]): Constify.Kaveh R. Ghazi1-2/+2
* alias.c (memory_modified_1, memory_modified_in_insn_p): Constify. * basic-block.h (tree_predicted_by_p, rtl_predicted_by_p): Likewise. * bb-reorder.c (copy_bb_p): Likewise. * cfghooks.c (can_remove_branch_p, can_merge_blocks_p, predicted_by_p, can_duplicate_block_p, block_ends_with_call_p, block_ends_with_condjump_p): Likewise. * cfghooks.h (can_remove_branch_p, can_merge_blocks_p, predicted_by_p, can_duplicate_block_p, block_ends_with_call_p, block_ends_with_condjump_p): Likewise. * cfglayout.c (cfg_layout_can_duplicate_bb_p): Likewise. * cfgrtl.c (can_delete_note_p, can_delete_label_p, rtl_can_merge_blocks, cfg_layout_can_merge_blocks_p, rtl_block_ends_with_call_p, rtl_block_ends_with_condjump_p, need_fake_edge_p, rtl_can_remove_branch_p): Likewise. * dbxout.c (dbx_debug_hooks, xcoff_debug_hooks): Use debug_true_const_tree instad of debug_true_tree. * debug.c (do_nothing_debug_hooks): Likewise. * debug.h (ignore_block, debug_true_const_tree): Constify. * dwarf2out.c (stack_adjust_offset, clobbers_queued_reg_save, dwarf2out_ignore_block, is_pseudo_reg, is_tagged_type, decl_ultimate_origin, block_ultimate_origin, lookup_decl_loc, same_dw_val_p, add_ranges, is_subrange_type, type_is_enum, dbx_reg_number, is_based_loc, field_type, simple_type_align_in_bits, simple_decl_align_in_bits, simple_type_size_in_bits, field_byte_offset, insert_float, type_tag, member_declared_type, is_redundant_typedef, secname_for_decl, is_inlined_entry_point): Likewise. * emit-rtl.c (const_next_insn, const_previous_insn, const_next_nonnote_insn, const_prev_nonnote_insn, const_next_real_insn, const_prev_real_insn, const_next_active_insn, const_prev_active_insn, const_next_label, const_prev_label): Likewise. * except.h (lookup_stmt_eh_region_fn, lookup_stmt_eh_region): Likewise. * haifa-sched.c (may_trap_exp, haifa_classify_insn, find_set_reg_weight, no_real_insns_p, find_set_reg_weight, sched_insn_is_legitimate_for_speculation_p): Likewise. * jump.c (reversed_comparison_code_parts, reversed_comparison_code, reversed_comparison, condjump_label): Likewise. * predict.c (rtl_predicted_by_p, tree_predicted_by_p): Likewise. * reg-stack.c (stack_regs_mentioned_p, stack_regs_mentioned): Likewise. * rtl.h (const_previous_insn, const_next_insn, const_prev_nonnote_insn, const_next_nonnote_insn, const_prev_real_insn, const_next_real_insn, const_prev_active_insn, const_next_active_insn, const_prev_label, const_next_label, modified_between_p, modified_in_p, const_note_storeskeep_with_call_p, condjump_label, reversed_comparison, reversed_comparison_code, reversed_comparison_code_parts, memory_modified_in_insn_p, stack_regs_mentioned): Likewise. * rtlanal.c (modified_between_p, modified_in_p, const_note_stores, keep_with_call_p): Likewise. * sched-deps.c (deps_may_trap_p, sched_get_condition, conditions_mutex_p, sched_insns_conditions_mutex_psd_next_list, sd_lists_size, sd_lists_empty_p): Likewise. * sched-int.h (sched_insns_conditions_mutex_p, haifa_classify_insn, no_real_insns_p, sched_insn_is_legitimate_for_speculation_p, sd_next_list, sd_lists_size, sd_lists_empty_p): Likewise. * sdbout.c (sdb_debug_hooks): Likewise. * tree-cfg.c (tree_can_merge_blocks_p, is_ctrl_altering_stmt, stmt_ends_bb_p, tree_can_remove_branch_p, tree_can_duplicate_bb_p, -tree_block_ends_with_call_p, tree_block_ends_with_condjump_p): Likewise. * tree-eh.c (lookup_stmt_eh_region_fn, lookup_stmt_eh_region, tree_can_throw_internal): Likewise. * tree-flow-inline.h (phi_nodes): Likewise. * tree-flow.h (phi_nodesstmt_ends_bb_p, is_ctrl_altering_stmt, tree_can_throw_internal, lookup_stmt_eh_region): Likewise. * tree-gimple.c (const_get_call_expr_in): Likewise. * tree-gimple.h (const_get_call_expr_in): Likewise. * tree.c (const_lookup_attribute, attribute_list_equal, attribute_list_contained): Likewise. * tree.h (attribute_list_equal, attribute_list_contained, const_lookup_attribute): Likewise. * vmsdbgout.c (vmsdbgout_ignore_block): Likewise. From-SVN: r127824
2007-08-14alias.c (rtx_equal_for_memref_p): Constify.Kaveh R. Ghazi1-2/+2
* alias.c (rtx_equal_for_memref_p): Constify. * basic-block.h (const_edge, const_basic_block): New. (reg_set_to_hard_reg_set, dfs_enumerate_from, single_succ_p, single_pred_p, single_succ_edge, single_pred_edge, single_succ, single_pred, maybe_hot_bb_p, probably_cold_bb_p, probably_never_executed_bb_p, edge_probability_reliable_p, br_prob_note_reliable_p, forwarder_block_p, flow_nodes_print, inside_basic_block_p, control_flow_insn_p, dominated_by_p): Likewise. * bb-reorder.c (better_edge_p, push_to_next_round_p): Likewise. * bt-load.c (basic_block_freq, insn_sets_btr_p, can_move_up): Likewise. * cfganal.c (flow_active_insn_p, forwarder_block_p, flow_nodes_print, dfs_enumerate_from): Likewise. * cfgbuild.c (count_basic_blocks, inside_basic_block_p, control_flow_insn_p, count_basic_blocks): Likewise. * cfgloop.c (flow_bb_inside_loop_p, glb_enum_p, get_loop_body_with_size, loop_exit_edge_p): Likewise. * cfgloop.h (flow_bb_inside_loop_p, num_loop_insns, average_num_loop_insns, loop_exit_edge_p, just_once_each_iteration_p, can_duplicate_loop_p): Likewise. * cfgloopanal.c (just_once_each_iteration_p, num_loop_insns, average_num_loop_insns, seq_cost): Likewise. * cfgloopmanip.c (rpe_enum_p, can_duplicate_loop_p): Likewise. * dominance.c (dominated_by_p): Likewise. * emit-rtl.c (validate_subreg): Likewise. * except.c (can_throw_internal, can_throw_external): Likewise. * except.h (can_throw_internal, can_throw_external): Likewise. * gcse.c (gcse_constant_p, oprs_unchanged_p, oprs_anticipatable_p, oprs_available_p, hash_expr, expr_equiv_p, oprs_not_set_p, compute_transp, load_killed_in_block_p, reg_killed_on_edge, simple_mem, store_ops_ok, load_kills_store, find_loads, store_killed_in_insn, store_killed_after, store_killed_before, gcse_mem_operand, implicit_set_cond_p, store_killed_in_pat): Likewise. * ifcvt.c (count_bb_insns, cheap_bb_rtx_cost_p, noce_operand_ok, noce_mem_write_may_trap_or_fault_p): Likewise. * pointer-set.c (pointer_set_contains, pointer_map_contains): Likewise. * pointer-set.h (pointer_set_contains, pointer_map_contains): Likewise. * predict.c (can_predict_insn_p, maybe_hot_bb_p, probably_cold_bb_p, probably_never_executed_bb_p, edge_probability_reliable_p, br_prob_note_reliable_p, can_predict_insn_p): Likewise. * regclass.c (reg_set_to_hard_reg_set): Likewise. * resource.c (return_insn_p): Likewise. * rtl.h (reg_set_between_p, reg_set_p, validate_subreg): Likewise. * rtlanal.c (reg_set_between_p, reg_set_p): Likewise. * tracer.c (count_insns, ignore_bb_p, better_p): Likewise. * tree-cfg.c (verify_gimple_unary_expr, verify_gimple_binary_expr, verify_gimple_modify_stmt): Likewise. * tree-chrec.c (is_not_constant_evolution, is_multivariate_chrec_rec, is_multivariate_chrec, chrec_contains_symbols, chrec_contains_undetermined, tree_contains_chrecs, evolution_function_is_affine_multivariate_p, evolution_function_is_univariate_p, avoid_arithmetics_in_type_p, eq_evolutions_p, scev_direction): Likewise. * tree-chrec.h (automatically_generated_chrec_p, tree_is_chrec, eq_evolutions_p, is_multivariate_chrec, chrec_contains_symbols, chrec_contains_symbols_defined_in_loop, chrec_contains_undetermined, tree_contains_chrecs, evolution_function_is_affine_multivariate_p, evolution_function_is_univariate_p, chrec_zerop, evolution_function_is_constant_p, evolution_function_is_affine_p, evolution_function_is_affine_or_constant_p, tree_does_not_contain_chrecs, chrec_type): Likewise. * tree-data-ref.c (tree_fold_divides_p, object_address_invariant_in_loop_p, dr_may_alias_p, ziv_subscript_p, siv_subscript_p, gcd_of_steps_may_divide_p, same_access_functions, constant_access_functions, access_functions_are_affine_or_constant_p, find_vertex_for_stmt): Likewise. * tree-flow.h (scev_direction): Likewise. * tree-gimple.c (is_gimple_stmt): Likewise. * tree-outof-ssa.c (identical_copies_p, identical_stmt_lists_p): Likewise. * tree-pretty-print.c (op_prio): Likewise. * tree-scalar-evolution.c (chrec_contains_symbols_defined_in_loop, analyzable_condition, backedge_phi_arg_p): Likewise. * tree-scalar-evolution.h (get_chrec_loop): Likewise. * tree-ssa-operands.c (get_name_decl, operand_build_cmp): Likewise. * tree-ssa-threadupdate.c (dbds_continue_enumeration_p): Likewise. From-SVN: r127404
2007-07-26Change copyright header to refer to version 3 of the GNU General Public ↵Nick Clifton1-6/+5
License and to point readers at the COPYING3 file and the FSF's license web page. From-SVN: r126948
2007-01-14tree-eh.c (add_stmt_to_eh_region_fn): Do not add call_exprs separately.Jan Hubicka1-4/+0
* tree-eh.c (add_stmt_to_eh_region_fn): Do not add call_exprs separately. (remove_stmt_from_eh_region_fn): Do not remove call_exprs. (verify_eh_throw_stmt_node, verify_eh_throw_table_statements): Kill. * except.h (verify_eh_throw_table_statements): Kill prototype. * cfgexpand.c (expand_gimple_basic_block): Propagate Eh regions into call exrepssions. * tree-optimize.c (execute_free_cfg_annotatiosn): Do not call eh trhow verifier. * tree-cfg.c: Include pointer-set.h. (verify_node_sharing): Work on pointer set. (verify_eh_throw_stmt_node): New. (verify_stmts): Use pointers sets, verify throw_stmt. From-SVN: r120766
2006-10-28except.h (output_function_exception_table): Add 'const char*' param.Eric Botcazou1-1/+1
* except.h (output_function_exception_table): Add 'const char*' param. * except.c (switch_to_exception_section): Add 'const char*' param. If named sections are supported and HAVE_LD_EH_GC_SECTIONS is defined and flag_function_sections is set, use a function-specific section. (output_function_exception_table): Add 'const char*' param. Adjust call to switch_to_exception_section. * final.c (rest_of_handle_final): Adjust calls to output_function_exception_table. * configure.ac (HAVE_LD_EH_GC_SECTIONS): New check. * config.in: Regenerate. * configure: Likewise. From-SVN: r118107
2006-04-15re PR middle-end/26823 (ICE with OpenMP in add_stmt_to_eh_region_fn, at ↵Jakub Jelinek1-0/+1
tree-eh.c:100) PR middle-end/26823 * except.h (eh_region_outermost): New prototype. * except.c (eh_region_outermost): New function. * tree-cfg.c (find_outermost_region_in_block): Use it. * g++.dg/gomp/pr26823-1.C: New test. * g++.dg/gomp/pr26823-2.C: New test. From-SVN: r112959
2006-03-22re PR middle-end/26084 (ICE (segfault) on C++ OpenMP code)Richard Henderson1-1/+3
PR middle-end/26084 * except.c (duplicate_eh_regions_0): New. (duplicate_eh_region_1): Duplicate the children of the node as well as the node itself. Link them up properly. (duplicate_eh_region_2): Merge into ... (duplicate_eh_regions): ... here. Take copy_region argument, and copy only a sub-tree if asked. Simplify copying and fixup. (eh_region_outer_p): New. * except.h (duplicate_eh_regions): Update decl. (eh_region_outer_p): Declare. * omp-low.c (lower_omp_single): Fix eh region placement wrt OMP_RETURN. (lower_omp_master): Likewise. (lower_omp_ordered): Likewise. * tree-cfg.c (struct move_stmt_d): Add new_label_map. (move_stmt_r): Use it to remap labels. Handle recursion vs remap_decls_p properly. (move_block_to_fn): Pass in new_label_map. Remap RESX_EXPR. (find_outermost_region_in_block): New. (new_label_mapper): New. (move_sese_region_to_fn): Copy eh information to the new function properly. * tree-inline.c (copy_cfg_body): Update for new duplicate_eh_regions argument. * tree-pretty-print.c (dump_generic_node): Dump RESX_EXPR region number. From-SVN: r112283
2006-03-02tree-vrp.c (execute_vrp): Return value.Daniel Berlin1-2/+2
2006-03-02 Daniel Berlin <dberlin@dberlin.org> * gcc/tree-vrp.c (execute_vrp): Return value. * gcc/regrename.c (rest_of_handle_regrename): Ditto. * gcc/tree-into-ssa.c (rewrite_into_ssa): Ditto. * gcc/tree-complex.c (tree_lower_complex): Ditto. (tree_lower_complex_O0): Ditto. * gcc/tracer.c (rest_of_handle_tracer): Ditto. * gcc/postreload-gcse.c (rest_of_handle_gcse2): Ditto. * gcc/postreload.c (rest_of_handle_postreload): Ditto. * gcc/tree-tailcall.c (execute_tail_recursion): Ditto. (execute_tail_calls): Ditto. * gcc/tree-ssa-loop-ch.c (copy_loop_headers): Ditto. * gcc/tree.h (init_function_for_compilation): Ditto. * gcc/ipa-cp.c (ipcp_driver): Ditto. * gcc/tree-scalar-evolution.c (scev_const_prop): Ditto. * gcc/tree-scalar-evolution.h (scev_const_prop): Ditto. * gcc/final.c (compute_alignments): Ditto. (rest_of_handle_final): Ditto. (rest_of_handle_shorten_branches): Ditto. (rest_of_clean_state): Ditto. * gcc/omp-low.c (execute_expand_omp): Ditto. (execute_lower_omp): Ditto. * gcc/tree-ssa-dse.c (tree_ssa_dse): Ditto. * gcc/ipa-reference.c (static_execute): Ditto. * gcc/tree-ssa-uncprop.c (tree_ssa_uncprop): Ditto. * gcc/reorg.c (rest_of_handle_delay_slots): Ditto. (rest_of_handle_machine_reorg): Ditto. * gcc/cgraphunit.c (rebuild_cgraph_edges): Ditto. * gcc/flow.c (recompute_reg_usage): Ditto. (rest_of_handle_remove_death_notes): Ditto. (rest_of_handle_life): Ditto. (rest_of_handle_flow2): Ditto. * gcc/tree-ssa-copyrename.c (rename_ssa_copies): Ditto. * gcc/tree-ssa-ccp.c (do_ssa_ccp): Ditto. (do_ssa_store_ccp): Ditto. (execute_fold_all_builtins): Ditto. * gcc/mode-switching.c (rest_of_handle_mode_switching): Ditto. * gcc/modulo-sched.c (rest_of_handle_sms): Ditto. * gcc/ipa-pure-const.c (static_execute): Ditto. * gcc/cse.c (rest_of_handle_cse): Ditto. (rest_of_handle_cse2): Ditto. * gcc/web.c (rest_of_handle_web): Ditto. * gcc/tree-stdarg.c (execute_optimize_stdarg): Ditto. * gcc/tree-ssa-math-opts.c (execute_cse_reciprocals): Ditto. * gcc/tree-ssa-dom.c (tree_ssa_dominator_optimize): Ditto. * gcc/tree-nrv.c (tree_nrv): Ditto. (execute_return_slot_opt): Ditto. * gcc/tree-ssa-alias.c (compute_may_aliases): Ditto. (create_structure_vars): Ditto. * gcc/loop-init.c (rtl_loop_init): Ditto. (rtl_loop_done): Ditto. (rtl_move_loop_invariants): Ditto. (rtl_unswitch): Ditto. (rtl_unroll_and_peel_loops): Ditto. (rtl_doloop): Ditto. * gcc/gimple-low.c (lower_function_body): Ditto. (mark_used_blocks): Ditto. * gcc/tree-ssa-sink.c (execute_sink_code): Ditto. * gcc/ipa-inline.c (cgraph_decide_inlining): Ditto. (cgraph_early_inlining): Ditto. * gcc/global.c (rest_of_handle_global_alloc): Ditto. * gcc/jump.c (cleanup_barriers): Ditto. (purge_line_number_notes): Ditto. * gcc/ifcvt.c (rest_of_handle_if_conversion): Ditto. (rest_of_handle_if_after_reload): Ditto. * gcc/tree-ssa-loop.c (tree_ssa_loop_init): Ditto. (tree_ssa_loop_im): Ditto. (tree_ssa_loop_unswitch): Ditto. (tree_vectorize): Ditto. (tree_linear_transform): Ditto. (tree_ssa_loop_ivcanon): Ditto. (tree_ssa_empty_loop): Ditto. (tree_ssa_loop_bounds): Ditto. (tree_complete_unroll): Ditto. (tree_ssa_loop_prefetch): Ditto. (tree_ssa_loop_ivopts): Ditto. (tree_ssa_loop_done): Ditto. * gcc/predict.c (tree_estimate_probability): Ditto. * gcc/recog.c (split_all_insns_noflow): Ditto. (rest_of_handle_peephole2): Ditto. (rest_of_handle_split_all_insns): Ditto. * gcc/tree-eh.c (lower_eh_constructs): Ditto. * gcc/regmove.c (rest_of_handle_regmove): Ditto. (rest_of_handle_stack_adjustments): Ditto. * gcc/local-alloc.c (rest_of_handle_local_alloc): Ditto. * gcc/function.c (instantiate_virtual_regs): Ditto. (init_function_for_compilation): Ditto. (rest_of_handle_check_leaf_regs): Ditto. * gcc/gcse.c (rest_of_handle_jump_bypass): Ditto. (rest_of_handle_gcse): Ditto. * gcc/ipa-type-escape.c (type_escape_execute): Ditto. * gcc/alias.c (rest_of_handle_cfg): Ditto. * gcc/tree-if-conv.c (main_tree_if_conversion): Ditto. * gcc/profile.c (rest_of_handle_branch_prob): Ditto. * gcc/tree-ssa-phiopt.c (tree_ssa_phiopt): Ditto. * gcc/rtl-factoring.c (rest_of_rtl_seqabstr): Ditto. * gcc/bt-load.c (rest_of_handle_branch_target_load_optimize): Ditto * gcc/tree-dfa.c (find_referenced_vars): Ditto. * gcc/except.c (set_nothrow_function_flags): Ditto. (convert_to_eh_region_ranges): Ditto. (rest_of_handle_eh): Ditto. * gcc/emit-rtl.c (unshare_all_rtl): Ditto. (remove_unnecessary_notes): Ditto. * gcc/except.h (set_nothrow_function_flags): Ditto. (convert_to_eh_region_ranges): Ditto. * gcc/cfgexpand.c (tree_expand_cfg): Ditto. * gcc/tree-cfgcleanup.c (merge_phi_nodes): Ditto. * gcc/tree-ssa-pre.c (do_pre): Ditto. (execute_fre): Ditto. * gcc/cfgcleanup.c (rest_of_handle_jump): Ditto. (rest_of_handle_jump2): Ditto. * gcc/tree-sra.c (tree_sra): Ditto. * gcc/tree-mudflap.c (execute_mudflap_function_ops): Ditto. (execute_mudflap_function_decls): Ditto. * gcc/tree-ssa-copy.c (do_copy_prop): Ditto. (do_store_copy_prop): Ditto. * gcc/ipa-prop.h (ipcp_driver): Ditto. * gcc/cfglayout.c (insn_locators_initialize): Ditto. * gcc/tree-ssa-forwprop.c (tree_ssa_forward_propagate_single_use_vars): Ditto. * gcc/cfglayout.h (insn_locators_initialize): Ditto. * gcc/tree-ssa-dce.c (tree_ssa_dce): Ditto. * gcc/tree-ssa.c (execute_early_warn_uninitialized): Ditto. (execute_late_warn_uninitialized): Ditto. * gcc/rtl.h (cleanup_barriers): Ditto. (split_all_insns_noflow): Ditto. (purge_line_number_notes): Ditto. (unshare_all_rtl): Ditto. (remove_unnecessary_notes): Ditto. (recompute_reg_usage): Ditto. (variable_tracking_main): Ditto. * gcc/integrate.c (emit_initial_value_sets): Ditto. * gcc/integrate.h (emit_initial_value_sets): Ditto. * gcc/tree-optimize.c (execute_free_datastructures): Ditto (execute_free_cfg_annotations): Ditto. (execute_fixup_cfg): Ditto. (execute_cleanup_cfg_pre_ipa): Ditto. (execute_cleanup_cfg_post_optimizing): Ditto. (execute_init_datastructures): Ditto. * gcc/tree-object-size.c (compute_object_sizes): Ditto. * gcc/combine.c (rest_of_handle_combine): Ditto. * gcc/tree-outof-ssa.c (rewrite_out_of_ssa): Ditto. * gcc/bb-reorder.c (duplicate_computed_gotos): Ditto. (rest_of_handle_reorder_blocks): Ditto. (rest_of_handle_partition_blocks): Ditto. * gcc/var-tracking.c (variable_tracking_main): Ditto. * gcc/tree-profile.c (tree_profiling): Ditto. * gcc/tree-vect-generic.c (expand_vector_operations): Ditto. * gcc/reg-stack.c (rest_of_handle_stack_regs): Ditto. * gcc/sched-rgn.c (rest_of_handle_sched): Ditto. (rest_of_handle_sched2): Ditto. * gcc/basic-block.h (free_bb_insn): Ditto. * gcc/tree-ssa-structalias.c (ipa_pta_execute): Ditto. * gcc/tree-cfg.c (execute_build_cfg): Ditto. (remove_useless_stmts): Ditto. (split_critical_edges): Ditto. (execute_warn_function_return): Ditto. (execute_warn_function_noreturn): Ditto. * gcc/tree-ssa-reassoc.c (execute_reassoc): Ditto. * gcc/cfgrtl.c (free_bb_for_insn): Ditto. * gcc/passes.c (execute_one_pass): Run additional todos returned by execute function. * gcc/tree-pass.h (struct tree_opt_pass): Make execute return a value. From-SVN: r111643
2006-01-06tree-cfg.c (bsi_replace): Rename final argument from PRESERVE_EH_INFO to ↵Jeff Law1-0/+4
UPDATE_EH_INFO. * tree-cfg.c (bsi_replace): Rename final argument from PRESERVE_EH_INFO to UPDATE_EH_INFO. Fix typo in last change (stmt -> orig_stmt). * tree-eh.c (verify_eh_throw_stmt_node): New function. (bsi_remove): Add new argument. Remove EH information if requested. (verify_eh_throw_table_statements): New function. (bsi_remove): Add new argument REMOVE_EH_INFO. All callers updated. * tree-optimize.c (execute_free_cfg_annotations): Verify the EH throw statement table after removing annotations. * except.h (verify_eh_throw_table_statements): Prototype. * tree-flow.h (bsi_remove): Update prototype. * tree-vrp.c (remove_range_assertions): Add new argument to bsi_remove call. * tree-ssa-loop-im.c (move_computations_stmt): Likewise. * tree-complex.c (expand_complex_div_wide): Likewise. * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges): Likewise * tree-tailcall.c (eliminate_tailcall): Likewise. * tree-ssa-dse.c (dse_optimize_stmt): Likewise. * tree-ssa-loop-ivopts.c (remove_statement): Likewise. * tree-nrv.c (tree_nrv): Likewise. * tree-vectorizer.c (slpeel_make_loop_iterate_ntimes): Likewise. * tree-if-conv.c (tree_if_convert_cond_expr): Likewise. (combine_blocks): Likewise. * tree-ssa-phiopt.c (replace_phi_edge_with_variable): Likewise. * tree-cfgcleanup.c (cleanup_ctrl_expr_graph): Likewise. (cleanup_control_flow): Likewise. (remove_forwarder_block): Likewise. * tree-ssa-pre.c (remove_dead_inserted_code): Likewise. * tree-sra.c (sra_replace): Likewise. * tree-ssa-forwprop.c (forward_propagate_into_cond): Likewise. (forward_propagate_single_use_vars): Likewise. * tree-ssa-dce.c (remove_dead_stmt): Likewise. * tree-inline.c (expand_call_inline): Likewise. * tree-vect-transform.c (vect_transform_loop): Likewise. * tree-outof-ssa.c (rewrite_trees): Likewise. * tree-cfg.c (make_goto_expr_edges): Likewise. (cleanup_dead_labels): Likewise. (tree_merge_blocks, remove_bb, disband_implicit_edges): Likewise. (bsi_move_before, bsi_move_after): Likewise. (bsi_move_to_bb_end, try_redirect_by_replacing_jump): Likewise (tree_redirect_edge_and_branch, tree_split_block): Likewise. From-SVN: r109421
2005-06-28Makefile.in: Set and use UNWIND_H.Paul Brook1-0/+1
2005-06-28 Paul Brook <paul@codesourcery.com> gcc/ * Makefile.in: Set and use UNWIND_H. Install as unwind.h. * c-decl.c (finish_decl): Call default_init_unwind_resume_libfunc. * except.c (add_ehspec_entry): Generate arm eabi filter lists. (assign_filter_values): Ditto. (output_ttype): New function. (output_function_exception_table): Use output_ttype. Generate arm eabi filter lists. (default_init_unwind_resume_libfunc): New function. * except.h (default_init_unwind_resume_libfunc): Add prototype. * optabs.c (init_optabs): Don't set unwind_resume_libfunc. * opts.c (decode_options): Use targetm.unwind_tables_default. * target-def.h (TARGET_ASM_TTYPE): Provide and use definition. (TARGET_ARM_EABI_UNWINDER, TARGET_UNWIND_TABLES_DEFAULT): Ditto. * target.h (struct gcc_target): Add asm.ttype, unwind_tables_default and arm_eabi_unwinder. * unwind-c.c: Support Arm EABI unwinder. * unwind.h: Rename ... * unwind-generic.h: ... To this. * doc/tm.texi (TARGET_ASM_TTYPE, TARGET_ARM_EABI_UNWINDER): Document. (TARGET_UNWID_TABLES_DEFAULT): Document. * config/arm/arm-protos.h (arm_output_fn_unwind): Add prototype. * config/arm/arm.c (arm_unwind_emit, arm_output_ttype): New functions. (TARGET_UNWIND_EMIT, TARGET_ASM_TTYPE, TARGET_ARM_EABI_UNWINDER): Define. (thumb_pushpop, thumb_output_function_prologue): Output unwinding directives. (arm_unwind_emit_stm, arm_unwind_emit_set): New functions. * config/arm/arm.h (MUST_USE_SJLJ_EXCEPTIONS): Only define when !TARGET_UNWIND_INFO. (ARM_OUTPUT_FN_UNWIND, ARM_EABI_UNWIND_TABLES): Define. * config/arm/bpabi.h (TARGET_UNWIND_INFO): Define. * config/arm/elf.h (ASM_DECLARE_FUNCTION_NAME, ASM_DECLARE_FUNCTION_SIZE): Use ARM_OUTPUT_FN_UNWIND. * config/arm/lib1funcs.asm: Include libunwind.S. * config/arm/libgcc-bpabi.ver: Add unwinding routines. * config/arm/libunwind.S: New file. * config/arm/pr-support.c: New file. * config/arm/t-bpabi (LIB1ASMFUNCS): Add _unwind. (UNWIND_H, LIB2ADDEH, LIB2ADDEHDEP): Set. * config/arm/t-symbian (UNWIND_H, LIB2ADDEH, LIB2ADDEHDEP): Set. * config/arm/unwind-arm.c: New file. * config/arm/unwind-arm.h: New file. * config/i386/t-netware (USER_H): Remove unwind.h. * config/ia64/ia64.h (TARGET_UNWIND_TABLES_DEFAULT): Define. gcc/cp/ * Make-lang.in (cp/except.o): Depend on $(TARGET_H) * except.c: Include target.h. (init_exception_processing): Initialize unwind_resume_libfunc. * doc/tm.texi: Document TARGET_ASM_TTYPE gcc/ada/ * misc.c (gnat_init_gcc_eh): Call default_init_unwind_resume_libfunc. gcc/java/ * decl.c (java_init_decl_processing): Call default_init_unwind_resume_libfunc. gcc/objc/ * objc-act.c (objc_init_exceptions): Call default_init_unwind_resume_libfunc. libstdc++/ * acinclude.m4 (GLIBCXX_ENABLE_SJLJ_EXCEPTIONS): Check for __cxa_end_cleanup. * libsupc++/Makefile.am (sources): Add eh_call.c and eh_arm.c. * libsupc++/eh_arm.cc: New file. * libsupc++/eh_call.cc: New file. * libsupc++/eh_catch.cc (__cxa_get_exception_ptr): Use __gxx_caught_object. (__cxa_begin_catch): Ditto. Use __is_gxx_exception_class. Call _Unwind_Complete when using the ARM EABI. (__cxa_end_catch): Use __is_gxx_exception_class. * libsupc++/eh_personality.cc: Define NO_SIZE_OF_ENCODED_VALUE when using the ARM EABI. (save_caught_exception, restore_caught_exception): New functions. (_throw_typet): New typedef. (get_ttype_entry, get_adjusted_ptr, check_exception_spec): Add ARM EABI implementations. (PERSONALITY_FUNCTION): Use new functions. Addd support for ARM EABI unwinding libary. (__cxa_unexpected): Disable when using the ARM EABI. * libsupc++/eh_throw.cc (__cxa_throw): Use __GXX_INIT_EXCEPTION_CLASS. (__cxa_rethrow): Use __is_gxx_exception_class. Call _Unwind_RaiseException when using the ARM EABI. * libsupc++/unwind-cxx.h (struct __cxa_exception): Add fields for ARM EABI semantics. (struct __cxa_eh_globals): Ditto. (__cxa_call_terminate): Add prototype. (__cxa_type_match, __cxa_begin_cleanup, __cxa_end_cleanup): Add prototypes. (__get_exception_header_from_obj, __get_exception_header_from_ue): Move earlier in file. (__is_gxx_exception_class, __GXX_INIT_EXCEPTION_CLASS, __gxx_caught_object): New functions. * aclocal.m4: Regenerate. * configure: Regenerate. * Makefile.in: Regenerate. * include/Makefile.in: Regenerate. * libmath/Makefile.in: Regenerate. * libsupc++/Makefile.in: Regenerate. * po/Makefile.in: Regenerate. * src/Makefie.in: Regenerate. * testsuite/makefile.in: Regenerate. From-SVN: r101385
2005-06-25Update FSF address.Kelley Cook1-2/+2
From-SVN: r101317
2005-05-27except.c (can_throw_internal_1, [...]): Add "is_resx" argument.Jan Hubicka1-2/+2
* except.c (can_throw_internal_1, can_throw_external_1): Add "is_resx" argument. (can_throw_external, can_throw_internal): Bring into sync wrt dealing resx. * except.h (can_throw_internal_1, can_throw_external_1): Update prototype. * tree-eh.c (tree_can_throw_internal, tree_can_throw_external): Deal properly with resx. From-SVN: r100282
2005-05-12except.c (duplicate_eh_region_1, [...]): New functions, based on old ↵Steven Bosscher1-0/+2
implementation removed with RTL inliner. * except.c (duplicate_eh_region_1, duplicate_eh_region_2, duplicate_eh_regions): New functions, based on old implementation removed with RTL inliner. (reachable_next_level): Modify behaviour pre-inline. * except.h (duplicate_eh_regions_map, duplicate_eh_regions): Declare. * function.h (struct function): Add after_inlining flag. * tree-optimize.c (tree_rest_of_compilation): Set it. * tree-eh.c (add_stmt_to_eh_region_fn): Initialize hashtable when needed. * tree-cfg.c (label_to_block_fn): Deal with cases where label was never insterted into code. Co-Authored-By: Jan Hubicka <jh@suse.cz> Co-Authored-By: Stuart Hastings <stuart@apple.com> From-SVN: r99625
2005-05-11Makefile.in (tree-eh.o): Kill gt-tree-eh.h dependency.Jan Hubicka1-0/+12
* Makefile.in (tree-eh.o: Kill gt-tree-eh.h dependency. (GTFILES): add except.h. * except.c (eh_status): Add throw_stmt_table. (set_eh_throw_stmt_table, get_eh_throw_stmt_table): New functions. * except.h (add_stmt_to_eh_region_fn, remove_stmt_from_eh_region_fn, lookup_stmt_eh_region_fn): Declare. (throw_stmt_node): New structure. (set_eh_throw_stmt_table, get_eh_throw_stmt_table): New. * gengtype.c (open_base_files): Add except.h to inlines. * tree-eh.c (throw_stmt_node): Kill. (record_stmt_eh_region): Update. (add_stmt_to_eh_region_fn): Break out from ... (add_stmt_to_eh_region): ... here. (remove_stmt_from_eh_region_fn): Break out from ... (remove_stmt_from_eh_region): ... here. (lookup_stmt_eh_region_fn): Break out from ... (lookup_stmt_eh_region): ... here. (honor_protect_cleanup_actions): Use build_resx. (lower_try_finally_onedest): Likewise. (lower_try_finally_copy): Likewise. (lower_try_finally_switch): Likewise. (lower_eh_constructs): Update eh table construction. * tree.c (build_resx): New. * tree.h (build_resx): Declare. From-SVN: r99585
2005-04-25tree-cfg.c (tree_duplicate_bb): Duplicate EH region too.Jan Hubicka1-0/+3
* tree-cfg.c (tree_duplicate_bb): Duplicate EH region too. * except.c: Include diagnostic.h (dump_eh_tree, verify_eh_tree): New functions. * except.h (verify_eh_tree, dump_eh_tree, verify_eh_edges): Declare. * tree-cfg.c (tree_verify_flow_info): verify eh edges. (dump_function_to_file): dump eh tree. * tree-eh.c (mark_eh_edge): New function. (mark_eh_edge_found_error): New static variable. (verify_eh_edges): New function. From-SVN: r98724
2005-03-14alloc-pool.c, [...]: Update copyright.Kazu Hirata1-1/+1
* alloc-pool.c, except.h, ggc-common.c, ggc-zone.c, ggc.h, stringpool.c, config/mips/mips-protos.h: Update copyright. From-SVN: r96428
2005-03-14except.c (check_handled): Make it static.Kazu Hirata1-1/+0
* except.c (check_handled): Make it static. * except.h: Remove the corresponding prototype. From-SVN: r96408
2004-11-13cse.c (CHEAP_REGNO): Redefine using REGNO_PTR_FRAME_P and HARD_REGISTER_NUM_P.Steven Bosscher1-3/+0
* cse.c (CHEAP_REGNO): Redefine using REGNO_PTR_FRAME_P and HARD_REGISTER_NUM_P. * cselib.c (new_cselib_val): Make comment correct and more detailed. * flow.c (mark_set_1): Likewise. * except.c (duplicate_eh_region_1, duplicate_eh_region_2, duplicate_eh_regions): Remove. * except.h (duplicate_eh_regions): Remove prototype. * integrate.c (get_label_from_map, copy_rtx_and_substitute, global_const_equiv_varray): Remove. * integrate.h (get_label_from_map, copy_rtx_and_substitute, global_const_equiv_varray, set_label_in_map): Remove prototypes, extern declaration, and #define. (MAYBE_EXTEND_CONST_EQUIV_VARRAY, SET_CONST_EQUIV_DATA): Remove. (struct inline_remap): Remove. * varray.c (struct element): Remove entry for const_equiv_data. * varray.h (struct const_equiv_data): Remove. (enum varray_data_enum) <VARRAY_DATA_CONST_EQUIV>: Remove. (union varray_data_tag) <const_equiv>: Remove. (VARRAY_CONST_EQUIV_INIT, VARRAY_CONST_EQUIV, VARRAY_PUSH_CONST_EQUIV, VARRAY_TOP_CONST_EQUIV): Remove. * regstack.c (record_label_references): Remove unused function. * rtl.def (VALUE): Update comment. (LABEL_REF): Remove unused operand 2. * rtl.h (struct rtx_def): Update for removed accessor macros. (XCADVFLAGS, INSN_DEAD_CODE_P, LINE_NUMBER, CONTAINING_INSN, REG_LOOP_TEST_P): Remove. (ADDR_DIFF_VEC_FLAGS, CSELIB_VAL_PTR, LABEL_NEXTREF): Add comments. * web.c (entry_register): Don't copy REG_LOOP_TEST_P. * doc/rtl.texi (INSN_DEAD_CODE_P, REG_LOOP_TEST_P): Remove. From-SVN: r90580
2004-07-15dwarf2out.c (dwarf2out_begin_prologue): Rename IA64_UNWIND_INFO to ↵Paul Brook1-3/+3
TARGET_UNWIND_INFO. * dwarf2out.c (dwarf2out_begin_prologue): Rename IA64_UNWIND_INFO to TARGET_UNWIND_INFO. * except.c (output_function_exception_table): Ditto. * except.h: Ditto. * opts.c (decode_options): Ditto. * passes.c (rest_of_handle_final): Ditto. * final.c (final_start_function): Ditto. (final_scan_insn, final_scan_insn): Replace IA64_UNWIND_EMIT with target hook. * targhooks.h (default_unwind_emit): Declare. * targhooks.c (default_unwind_emit): New function. * target-def.h: Define and use TARGET_UNWIND_EMIT. * target.h (struct gcc_target): Add unwind_emit. * config/ia64/ia64.c (TARGET_UNWIND_EMIT): Define. * config/ia64/ia64.h: Rename IA64_UNWIND_INFO to TARGET_UNWIND_INFO. Remove IA64_UNWIND_EMIT. * doc/tm.texi: Document TARGET_UNWIND_EMIT and TARGET_UNWIND_INFO. From-SVN: r84734
2004-07-08except.c (expand_eh_region_start, [...]): Remove.Richard Henderson1-46/+0
* except.c (expand_eh_region_start, expand_eh_region_end, expand_eh_handler, expand_eh_region_end_cleanup, expand_start_all_catch, expand_start_catch, expand_end_catch, expand_end_all_catch, expand_eh_region_end_allowed, expand_eh_region_end_must_not_throw, expand_eh_region_end_throw, expand_eh_region_end_fixup): Remove. * stmt.c (struct nesting): Remove stack_level, innermost_stack_block, cleanups, outer_cleanups, label_chain, exception_region. (struct goto_fixup): Remove stack_level, cleanup_list_list. (struct label_chain): Remove. (struct stmt_status): Remove x_stack_block_stack. (stack_block_stack, expand_goto_internal, expand_fixup, expand_fixups, fixup_gotos, save_stack_pointer, expand_decl_cleanup, expand_decl_cleanup_eh, expand_cleanups, start_cleanup_deferral, end_cleanup_deferral, last_cleanup_this_contour, containing_blocks_have_cleanups_or_stack_level, any_pending_cleanups): Remove. (expand_null_return_1): Take no arguments. (expand_label, expand_naked_return, expand_return, expand_start_bindings_and_block, expand_end_bindings, expand_decl, expand_anon_union_decl, expand_start_case, pushcase, pushcase_range, expand_end_case_type): Don't use any of them. * calls.c (expand_call): Likewise. * dojump.c (do_jump): Likewise. * function.c (expand_function_end): Likewise. * expr.c (store_expr, expand_expr_real_1): Likewise. (safe_from_p): Don't handle WITH_CLEANUP_EXPR, CLEANUP_POINT_EXPR. (expand_expr_real_1): Don't handle WITH_CLEANUP_EXPR, CLEANUP_POINT_EXPR, TARGET_EXPR, TRY_CATCH_EXPR, CATCH_EXPR, EH_FILTER_EXPR, TRY_FINALLY_EXPR, GOTO_SUBROUTINE_EXPR. * fold-const.c (fold_checksum_tree): Use first_rtl_op. * gengtype.c (adjust_field_tree_exp): Remove rtl op handling. * gimplify.c (gimplify_cleanup_point_expr): Renumber operands for WITH_CLEANUP_EXPR. (gimple_push_cleanup): Likewise. * integrate.c (copy_decl_for_inlining): Don't DECL_TOO_LATE. * print-tree.c (print_node): Likewise. * tree-pretty-print.c (dump_generic_node): Remove GOTO_SUBROUTINE_EXPR. * tree.c (first_rtl_op): Always just TREE_CODE_LENGTH. (has_cleanups): Remove GOTO_SUBROUTINE_EXPR. * tree.def (WITH_CLEANUP_EXPR): Remove op1 and op2. (GOTO_SUBROUTINE_EXPR): Remove. * tree.h (WITH_CLEANUP_EXPR_RTL): Remove. (DECL_TOO_LATE): Remove. * except.h, tree.h: Update decls. ada/ * trans.c (gnat_to_gnu <N_Handled_Sequence_Of_Statements>): Update commentary. cp/ * cp-tree.h (expand_eh_spec_block): Remove. java/ * expr.c (case_identity, get_primitive_array_vtable, java_expand_expr, emit_init_test_initialization): Remove. * java-tree.h (java_expand_expr): Remove. * lang.c (LANG_HOOKS_EXPAND_EXPR): Remove. From-SVN: r84275
2004-07-08explow.c (optimize_save_area_alloca): Do not accept parameters.Paolo Bonzini1-1/+1
2004-07-08 Paolo Bonzini <bonzini@gnu.org> * explow.c (optimize_save_area_alloca): Do not accept parameters. * passes.c (rest_of_handle_final): Handle symout. (rest_of_handle_new_regalloc, rest_of_handle_old_regalloc): Push timevar here. (rest_of_handle_sched): Break out SMS. Remove ifs for flag_schedule_insns and flag_modulo_sched. (rest_of_handle_addressof, rest_of_handle_cse2): Garbage collect at the end. (rest_of_handle_gcse2): Put under timevar TV_RELOAD_CSE_REGS. (rest_of_handle_partition_blocks, rest_of_handle_sms, rest_of_handle_if_after_reload, rest_of_handle_peephole2, rest_of_handle_mode_switching, rest_of_handle_jump, rest_of_handle_guess_branch_prob, rest_of_handle_eh, rest_of_handle_jump2, rest_of_handle_postreload, rest_of_handle_flow2, rest_of_clean_state, rest_of_handle_shorten_branches, rest_of_handle_prologue_epilogue, rest_of_handle_branch_target_load_optimize): New. (rest_of_compilation): Call the above. Remove ggc_collect calls moved to rest_of_handle_*. * rtl.h (optimize_save_area_alloca): Do not accept parameters. * dwarf2out.c (dwarf2out_begin_prologue): Use TREE_NOTHROW. * except.c (set_nothrow_function_flags): Set TREE_NOTHROW. * except.h (set_nothrow_function_flags): Update comment. * function.c (current_function_nothrow): Remove. * output.h (current_function_nothrow): Remove. * passes.c (rest_of_compilation): Do not set TREE_NOTHROW. * config/arm/arm.c (arm_compute_func_type): Use TREE_NOTHROW. From-SVN: r84274
2004-06-04except.c (for_each_eh_region): New function.Steven Bosscher1-0/+3
* except.c (for_each_eh_region): New function. * except.h (for_each_eh_region): Add a prototype for it. * tree-cfg.c (update_eh_labels): New function, callback for for_each_eh_region. (label_for_bb): Make global static, unfortunately. (cleanup_dead_labels): Also update label references for exception regions. From-SVN: r82622
2004-05-13Merge tree-ssa-20020619-branch into mainline.Diego Novillo1-1/+29
From-SVN: r81764
2004-02-18cfgloop.h, [...]: Update copyright.Kazu Hirata1-1/+1
gcc/ * cfgloop.h, cfgloopanal.c, cpplex.c, except.h, loop-init.c, loop-unroll.c, scan-decls.c, scan.h, stor-layout.c, xcoffout.c, xcoffout.h, config/arm/mmintrin.h, config/mips/linux64.h, config/pa/pa-64.h, config/rs6000/aix51.h, config/rs6000/aix52.h, config/rs6000/spe.md, config/sparc/linux.h, config/sparc/linux64.h: Update copyright. gcc/cp/ * cp-tree.def, cvt.c: Update copyright. From-SVN: r78032
2004-02-09re PR libstdc++/5625 ([mips] exception unwinding creates invalid pointer on ↵James E Wilson1-0/+1
mips) PR libstdc++/5625 * builtin-types.def (BT_WORD, BT_FN_WORD_PTR): New. * builtins.c (expand_builtin): Handle BUILT_IN_EXTEND_POINTER. * builtins.def (BUILT_IN_EXTEND_POINTER): New. * except.c (expand_builtin_extend_pointer): New. * except.h (expand_builtin_extend_pointer): Declare. From-SVN: r77554
2003-10-01except.h (MUST_USE_SJLJ_EXCEPTIONS): Revert 2003-09-23 change.Rainer Orth1-6/+4
* except.h (MUST_USE_SJLJ_EXCEPTIONS): Revert 2003-09-23 change. Allow override. * doc/tm.texi (MUST_USE_SJLJ_EXCEPTIONS): Document. From-SVN: r71985
2003-09-23except.h (MUST_USE_SJLJ_EXCEPTIONS): Test for DWARF2_UNWIND_INFO value.Rainer Orth1-2/+6
* except.h (MUST_USE_SJLJ_EXCEPTIONS): Test for DWARF2_UNWIND_INFO value. From-SVN: r71690
2003-06-29except.c: Convert prototypes to ISO C90.Andreas Jaeger1-42/+41
* except.c: Convert prototypes to ISO C90. * except.h: Likewise. * emit-rtl.c: Likewise. * et-forest.c: Likewise. * et-forest.h: Likewise. * except.c: Likewise. * explow.c: Likewise. * expmed.c: Likewise. * expr.c: Likewise. * expr.h: Likewise. From-SVN: r68674
2003-05-10except.c (EH_RETURN_STACKADJ_RTX): Do not define.Ulrich Weigand1-4/+0
* except.c (EH_RETURN_STACKADJ_RTX): Do not define. (EH_RETURN_HANDLER_RTX): Likewise. (expand_builtin_eh_return): Do not copy stack adjustment if EH_RETURN_STACKADJ_RTX is not defined. (expand_eh_return): Likewise. Also, do not pass stack adjustment as argument to the eh_return pattern. * except.h (MUST_USE_SJLJ_EXCEPTIONS): Do not define just because EH_RETURN_STACKADJ_RTX is not defined. * unwind-dw.c (uw_update_context_1): If EH_RETURN_STACKADJ_RTX is not defined, treat stack pointer like a regular register. (uw_init_context_1): Set up fake initial stack pointer register. (uw_install_context_1): Do not compute stack adjustment if EH_RETURN_STACKADJ_RTX is not defined. * config/i386/i386.md ("eh_return"): Remove first argument. * config/mips/mips.md ("eh_return"): Likewise. * config/rs6000/rs6000.md ("eh_return"): Likewise. * config/sh/sh.md ("eh_return"): Likewise. * config/s390/s390.h (EH_RETURN_STACKADJ_RTX): Remove. From-SVN: r66672
2003-05-03builtins.c (expand_builtin): Remove.Richard Henderson1-1/+1
* builtins.c (expand_builtin) <BUILT_IN_DWARF_FP_REGNUM>: Remove. <BUILT_IN_DWARF_SP_COLUMN>: New. * builtins.def (BUILT_IN_DWARF_FP_REGNUM): Remove. (BUILT_IN_DWARF_SP_COLUMN): New. * dwarf2out.c (expand_builtin_dwarf_fp_regnum): Remove. (expand_builtin_dwarf_sp_column): New. * except.h: Update to match. * unwind-dw2.c (execute_stack_op): Correct stack push typo. (execute_cfa_program): Record location expression address before extracting length. (uw_update_context_1): Install old CFA into stack pointer column. (uw_init_context_1): Set cfa_reg to stack pointer column. From-SVN: r66447
2003-04-22Makefile.in (calls.o): Depend on except.h.Mark Mitchell1-0/+4
* Makefile.in (calls.o): Depend on except.h. * calls.c: Include except.h. (emit_call_1): Call note_eh_region_may_contain_throw if appropriate. * except.c (eh_region): Add may_contain_throw. (expand_eh_region_end_cleanup): Do not include handler code when it cannot be reached. (note_eh_region_may_contain_throw): New function. * except.h (note_eh_region_may_contain_throw): New function. * call.c (build_over_call): Use build_cxx_call. (build_cxx_call): New method, split out of build_over_call. * cp-tree.h (language_function): Add can_throw. (build_cxx_call): Declare it. * decl.c (finish_function): If a function does not contain any calls to functions that can throw an exception, indicate that fact. * decl2.c (mark_used): Do not defer the instantiation of functions, if the current function does not throw. * optimize.c (maybe_clone_body): Copy TREE_NOTHROW to the clones. * pt.c (instantiate_decl): Make sure import_export_decl is called before emitting things. * rtti.c (throw_bad_cast): Use build_cxx_call. (build_dynamic_cast_1): Likewise. * typeck.c (build_function_call): Likewise. * g++.dg/template/recurse.C: Adjust location of error messages. From-SVN: r65929
2003-03-31* except.h: Remove definition of varray_type.Matt Kraai1-9/+0
From-SVN: r65074
2002-08-25function.h (struct function): Add flag all_throwers_are_sibcalls.Stuart Hastings1-2/+2
2002-08-24 Stuart Hastings <stuart@apple.com> * function.h (struct function): Add flag all_throwers_are_sibcalls. * except.c (set_nothrow_function_flags): Replaces nothrow_function_p. Set new flag. * except.h (set_nothrow_function_flags): Replaces nothrow_function_p. * dwarf2out.c (struct dw_fde_struct): Add flag all_throwers_are_sibcalls. (output_call_frame_info): Test it. (dwarf2out_begin_prologue) Propagate it from cfun to dw_fde_struct. * toplev.c (rest_of_compilation): Update calls to nothrow_function_p. From-SVN: r56561
2002-04-09basic-block.h (flow_delete_block_noexpunge): Declare.Richard Henderson1-3/+4
* basic-block.h (flow_delete_block_noexpunge): Declare. (expunge_block_nocompact): Declare. * cfg.c (expunge_block_nocompact): Split out from ... (expunge_block): ... here. * cfgrtl.c (can_delete_label_p): Don't use exception_handler_labels. (flow_delete_block_noexpunge): Split out from ... (flow_delete_block): ... here. * cfgcleanup.c (delete_unreachable_blocks): Compact while removing dead blocks. * except.c (exception_handler_labels): Remove. (exception_handler_label_map): New. (struct eh_region): Add aka member. (mark_ehl_map_entry, mark_ehl_map, free_region): New. (ehl_hash, ehl_eq, ehl_free, add_ehl_entry): New. (for_each_eh_label, for_each_eh_label_1): New. (init_eh): Register exception_handler_label_map. (free_eh_status): Use free_region. (find_exception_handler_labels): Use the map, not the list. (remove_exception_handler_label): Likewise. (maybe_remove_eh_handler): Likewise. (remove_eh_handler): Use the region aka bitmap. * except.h (exception_handler_labels): Remove. (for_each_eh_label): Declare. * jump.c (rebuild_jump_labels): Don't check exception_handler_labels. * loop.c (invalidate_loops_containing_label): New. (find_and_verify_loops): Use it. Use for_each_eh_label. * sched-rgn.c (is_cfg_nonregular): Use current_function_has_exception_handlers. From-SVN: r52100
2002-04-03re PR c++/5636 (gcc-3.0.3, memory leakage: function that take a string as ↵Jason Merrill1-14/+0
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
2002-03-19except.c (current_function_has_exception_handlers): New.Richard Henderson1-0/+1
* except.c (current_function_has_exception_handlers): New. * except.h: Declare it. * sibcall.c (optimize_sibling_and_tail_recursive_call): Use it. Combine tests that disable all sibcalls for the function. From-SVN: r51054
2002-01-12attribs.c (handle_deprecated_attribute): constify WHAT.Graham Stott1-5/+4
* attribs.c (handle_deprecated_attribute): constify WHAT. * diagnostic.c (warn_deprecated_use): Add braces, fixes dangling else warning and constify WHAT. * except.h (struct function, struct inline_remap): Move struct tag forward defs before all prototypes. (duplicate_eh_regions): Whitespace. From-SVN: r48799
2001-12-31except.h: Remove forward def of tree_node, rtx_def and define of tree, rtx.Graham Stott1-18/+0
* except.h: Remove forward def of tree_node, rtx_def and define of tree, rtx. Also remove undefs. From-SVN: r48416
2001-11-23ChangeLog.0, [...]: Fix spelling errors.Joseph Myers1-1/+1
* ChangeLog.0, ChangeLog.2, ChangeLog.3, ChangeLog.4, ChangeLog, FSFChangeLog.10, c-decl.c, cppfiles.c, cppinit.c, cpplex.c, cpplib.c, cppmain.c, cse.c, df.c, diagnostic.c, dominance.c, dwarf2out.c, dwarfout.c, emit-rtl.c, errors.c, except.c, except.h, explow.c, function.c, gcse.c, genrecog.c, predict.c, regmove.c, sched-rgn.c, ssa-ccp.c, stmt.c, toplev.c: Fix spelling errors. From-SVN: r47279
2001-11-16except.c: Support for catching a list of types with a single handler (struct ↵Olivier Hainque1-1/+2
eh_region):... * except.c: Support for catching a list of types with a single handler (struct eh_region): Change type and filter to lists for catch regions. (mark_eh_region): Mark the filter list for GC also. (expand_start_catch): Always build a list if argument not NULL and register each type of the list through add_type_for_runtime. (duplicate_eh_region_1): Change type into type_list for catch regions. (assign_filter_values): Assign a filter to each type associated with a catch region. Assign filter for NULL types in a unique entry in the filter list. (build_post_landing_pads): Emit compare and jump for each filter of the list associated with a catch region. (reachable_next_level): When the type thrown is known, stop the search as soon as one type within a catch list matches. Also, a handler is potentially reachable only if at least one of the types it catches has not been previously caught. (collect_one_action_chain): Retrieve the filter for a NULL type list from the first filter list entry. For non NULL type lists, add an action record for every filter assigned. * except.h: Reflect changes in comment before expand_start_catch. From-SVN: r47087
2001-10-28ChangeLog.0, [...]: Fix spelling errors.Joseph Myers1-1/+1
* ChangeLog.0, ChangeLog.1, ChangeLog.2, ChangeLog.3, ChangeLog.4, ChangeLog.5, ChangeLog, FSFChangeLog.10, FSFChangeLog.11, c-common.c, c-common.h, c-parse.in, c-typeck.c, cfg.c, config.gcc, configure, configure.in, except.c, except.h, flow.c, function.c, gcc.c, gcse.c, genrecog.c, libgcc2.c, loop.c, loop.h, params.def, predict.def, predict.h, reg-stack.c, regmove.c, sched-deps.c, sched-int.h, sibcall.c, ssa.c, stringpool.c, toplev.c, tree.c, unroll.c: Fix spelling errors. From-SVN: r46595
2001-08-22Makefile.in, [...]: replace "GNU CC" with "GCC".Lars Brinkhoff1-12/+12
* Makefile.in, alias.c, basic-block.h, bb-reorder.c, bitmap.c, bitmap.h, builtin-types.def, builtins.c, builtins.def, c-aux-info.c, c-common.c, c-common.def, c-common.h, c-convert.c, c-decl.c, c-dump.c, c-dump.h, c-errors.c, c-format.c, c-lang.c, c-lex.c, c-lex.h, c-parse.in, c-pragma.c, c-pragma.h, c-semantics.c, c-tree.h, c-typeck.c, caller-save.c, calls.c, collect2.c, collect2.h, combine.c, conditions.h, config.gcc, configure.frag, configure.in, conflict.c, convert.c, convert.h, cppspec.c, crtstuff.c, cse.c, cselib.c, cselib.h, dbxout.c, dbxout.h, defaults.h, dependence.c, df.c, df.h, diagnostic.c, diagnostic.h, doloop.c, dominance.c, dwarf.h, dwarf2.h, dwarf2asm.c, dwarf2asm.h, dwarf2out.c, dwarf2out.h, dwarfout.c, emit-rtl.c, errors.c, errors.h, except.c, except.h, exgettext, explow.c, expmed.c, expr.c, expr.h, final.c, fixproto, flags.h, flow.c, fold-const.c, fp-test.c, function.c, function.h, gbl-ctors.h, gcc.c, gcc.h, gcc.hlp, gccspec.c, gcov-io.h, gcse.c, genattr.c, genattrtab.c, gencheck.c, gencodes.c, genconfig.c, genemit.c, genextract.c, genflags.c, gengenrtl.c, genmultilib, genopinit.c, genoutput.c, genpeep.c, genrecog.c, gensupport.c, gensupport.h, ggc-callbacks.c, ggc-common.c, ggc-none.c, ggc-page.c, ggc-simple.c, ggc.h, global.c, graph.c, graph.h, gthr-aix.h, gthr-dce.h, gthr-posix.h, gthr-rtems.h, gthr-single.h, gthr-solaris.h, gthr-vxworks.h, gthr-win32.h, gthr.h, haifa-sched.c, halfpic.c, halfpic.h, hard-reg-set.h, hwint.h, ifcvt.c, input.h, insn-addr.h, integrate.c, integrate.h, jump.c, lcm.c, libgcc2.c, libgcc2.h, lists.c, local-alloc.c, loop.c, loop.h, machmode.def, machmode.h, main.c, mbchar.c, mbchar.h, mips-tdump.c, mips-tfile.c, mklibgcc.in, mkmap-flat.awk, mkmap-symver.awk, optabs.c, output.h, params.c, params.def, params.h, predict.c, predict.def, predict.h, prefix.c, prefix.h, print-rtl.c, print-tree.c, profile.c, protoize.c, read-rtl.c, real.c, real.h, recog.c, recog.h, reg-stack.c, regclass.c, regmove.c, regrename.c, regs.h, reload.c, reload.h, reload1.c, reorg.c, resource.c, resource.h, rtl.c, rtl.def, rtl.h, rtlanal.c, sbitmap.c, sbitmap.h, sched-deps.c, sched-ebb.c, sched-int.h, sched-rgn.c, sched-vis.c, sdbout.c, sdbout.h, sibcall.c, simplify-rtx.c, ssa-ccp.c, ssa-dce.c, ssa.c, ssa.h, stmt.c, stor-layout.c, stringpool.c, system.h, timevar.c, timevar.def, timevar.h, tlink.c, toplev.c, toplev.h, tree.c, tree.def, tree.h, tsystem.h, unroll.c, unwind-dw2-fde.c, unwind-dw2-fde.h, unwind-dw2.c, unwind-pe.h, unwind-sjlj.c, unwind.h, unwind.inc, varasm.c, varray.c, varray.h, xcoffout.c, xcoffout.h: replace "GNU CC" with "GCC". From-SVN: r45105
2001-07-06except.h (MUST_USE_SJLJ_EXCEPTIONS): Examine the value of DWARF2_UNWIND_INFO ↵Richard Henderson1-1/+1
not just whether it is defined. * except.h (MUST_USE_SJLJ_EXCEPTIONS): Examine the value of DWARF2_UNWIND_INFO not just whether it is defined. From-SVN: r43829
2001-06-08except.c (get_exception_pointer, [...]): Take a struct function.Richard Henderson1-1/+1
* except.c (get_exception_pointer, get_exception_filter): Take a struct function. Update all callers. * except.h (get_exception_pointer): Update declaration. * expr.c (expand_expr): Update get_exception_pointer call. * integrate.c (expand_inline_function): Remap the exception pointer from callee to caller. From-SVN: r43060
2001-05-25Standardize header guards.Richard Henderson1-2/+2
From-SVN: r42615
2001-05-17except.h (protect_cleanup_actions): Remove it.Mark Mitchell1-2/+7
* except.h (protect_cleanup_actions): Remove it. (lang_protect_cleanup_actions): Declare it. * except.c (protect_cleanup_actions): Remove it. (lang_protect_cleanup_actions): New variable. (init_eh): Don't make protect_cleanup_actions a GC root. (expand_eh_region_and_cleanup): Call lang_protect_cleanup_actions. (output_function_exception_table): Remove unused `align' variable. * varasm.c (assemble_external): Abort if we have not yet opened the assembly output file. * except.c (cp_protect_cleanup_actions): New function. (init_exception_processing): Don't set protect_cleanup_actions here. Do set lang_protect_cleanup_actions. From-SVN: r42218
2001-05-11defaults.h (ASM_PREFERRED_EH_DATA_FORMAT): New.Richard Henderson1-6/+6
* defaults.h (ASM_PREFERRED_EH_DATA_FORMAT): New. * dwarf2asm.c (dw2_force_const_mem, dw2_output_indirect_constant_1, dw2_output_indirect_constants, dw2_asm_output_encoded_addr_rtx): New. * dwarf2asm.h (dw2_asm_output_encoded_addr_rtx): Prototype. (dw2_output_indirect_constants): Prototype. * dwarf2out.c (dwarf2out_begin_prologue): Generate current_function_func_begin_label if we'll need it for EH. Exit early for IA64_UNWIND_INFO. * except.c: Get DW_EH_PE_* defines from dwarf2.h. (eh_data_format_name): Update for indirect references. (output_function_exception_table): Care for IA64_UNWIND_INFO. Handle ASM_PREFERRED_EH_DATA_FORMAT. * except.h (MUST_USE_SJLJ_EXCEPTIONS): IA64_UNWIND_INFO needn't define HAVE_eh_return etc. * final.c (final_start_function): Always call dwarf2out_begin_prologue. (final_end_function): Don't call output_function_exception_table. * toplev.c (compile_file): Call dw2_output_indirect_constants. (rest_of_compilation): Invoke output_function_exception_table for ia64 before assemble_end_function. * tm.texi (ASM_PREFERRED_EH_DATA_FORMAT): Document. (ASM_MAYBE_OUTPUT_ENCODED_ADDR_RTX): Document. * unwind-dw2.c (_Unwind_GetTextRelBase, _Unwind_GetDataRelBase): New. * unwind.h: Declare them. * libgcc-std.ver: Export them. * unwind-pe.h: New file. * config/alpha/elf.h (ASM_PREFERRED_EH_DATA_FORMAT): New. * config/ia64/fde-glibc.c: Use "struct unw_table_entry" instead of "fde". (find_fde_for_dso): Extract DT_PLTGOT. (_Unwind_FindTableEntry): Rename from __ia64_find_fde; return the segment and gp as well. * config/ia64/frame-ia64.c: Remove file. * config/ia64/frame-ia64.h: Remove file. * config/ia64/unwind-ia64.c: New file. * config/ia64/unwind-ia64.h: New file. * config/ia64/ia64.h (ASM_OUTPUT_EH_CHAR): Remove. (ASM_OUTPUT_EH_SHORT, ASM_OUTPUT_EH_INT): Remove. (ASM_OUTPUT_EH_DOUBLE_INT): Remove. (ASM_PREFERRED_EH_DATA_FORMAT): New. (ASM_MAYBE_OUTPUT_ENCODED_ADDR_RTX): New. (IA64_UNWIND_INFO): Re-enable. (HANDLER_SECTION): Remove. (EH_RETURN_DATA_REGNO): New. * config/ia64/ia64.md (exception_receiver): Remove. * config/ia64/t-glibc (LIB2ADDEH): Re-enable. * config/ia64/t-ia64 (LIB2ADDEH): Re-enable. From-SVN: r41981
2001-05-04except.h: Add prototype declaration for expand_builtin_init_dwarf_reg_sizes.Andreas Jaeger1-1/+3
* except.h: Add prototype declaration for expand_builtin_init_dwarf_reg_sizes. From-SVN: r41823
2001-04-02except.h (lang_eh_type_covers): Mark extern.Richard Henderson1-2/+2
* except.h (lang_eh_type_covers): Mark extern. (lang_eh_runtime_type): Likewise. From-SVN: r41024
2001-04-01* except.h (expand_builtin_dwarf_fp_regnum): Declare.Richard Henderson1-0/+1
From-SVN: r40995