#include "config.h"#include "system.h"#include "coretypes.h"#include "tm.h"#include "tree.h"#include "rtl.h"#include "tm_p.h"#include "function.h"#include "tree-dump.h"#include "tree-inline.h"#include "tree-gimple.h"#include "tree-iterator.h"#include "tree-flow.h"#include "cgraph.h"#include "expr.h"#include "langhooks.h"#include "ggc.h"#include "gt-tree-nested.h"

Go to the source code of this file.
| #define create_tmp_var cant_use_create_tmp_var_here_dummy |
Definition at line 125 of file tree-nested.c.
Referenced by abs_replacement(), adjust_accumulator_values(), adjust_return_value(), build_stack_save_restore(), conditional_replacement(), create_expression_by_pieces(), create_iv(), create_one_component_var(), create_temp(), create_tmp_from_val(), cxx_omp_clause_apply_fn(), determine_invariantness_stmt(), do_return_redirection(), expand_omp_for_generic(), expand_omp_sections(), expand_parallel_call(), factor_computed_gotos(), gimple_push_cleanup(), gimplify_cond_expr(), gimplify_decl_expr(), gimplify_init_ctor_eval_range(), gimplify_omp_atomic_pipeline(), gimplify_one_sizepos(), gimplify_parameters(), gimplify_return_expr(), honor_protect_cleanup_actions(), ifc_temp_var(), init_tmp_var(), insert_extra_phis(), insert_fake_stores(), insert_into_preds_of_block(), ix86_gimplify_va_arg(), lambda_loopnest_to_gcc_loopnest(), lbv_to_gcc_expression(), lle_to_gcc_expression(), lower_function_body(), lower_omp_parallel(), lower_omp_single_copy(), lower_try_finally_switch(), make_rename_temp(), mf_build_check_statement_for(), mf_decl_cache_locals(), perfect_nestify(), replace_uses_equiv_to_x_with_y(), rewrite_address_base(), rs6000_gimplify_va_arg(), s390_gimplify_va_arg(), save_tmp_var(), sh_gimplify_va_arg_expr(), sparc_gimplify_va_arg(), tree_divmod_fixed_value(), tree_gen_edge_profiler(), tree_mod_pow2(), tree_mod_subtract(), tree_optimize_tail_calls_1(), tree_unroll_loop(), vect_build_loop_niters(), vect_create_addr_base_for_vector_ref(), vect_create_cond_for_align_checks(), vect_create_data_ref_ptr(), vect_gen_niters_for_prolog_loop(), vect_generate_tmps_on_preheader(), vect_get_new_vect_var(), vect_pattern_recog_1(), vect_update_ivs_after_vectorizer(), voidify_wrapper_expr(), xstormy16_expand_builtin_va_arg(), and xtensa_gimplify_va_arg_expr().
Definition at line 154 of file tree-nested.c.
References base, build1, build_pointer_type(), DECL_P, handled_component_p(), TREE_ADDRESSABLE, TREE_OPERAND, and TREE_TYPE.
Referenced by add_address_candidates(), addr_for_mem_ref(), convert_nl_goto_reference(), convert_tramp_reference(), create_mem_ref(), finalize_nesting_tree_1(), find_interesting_uses_address(), get_static_chain(), lower_builtin_setjmp(), lower_function_body(), tree_gen_interval_profiler(), tree_gen_one_value_profiler(), tree_gen_pow2_profiler(), and tree_mem_ref_addr().
Definition at line 663 of file tree-nested.c.
References cgraph_node(), DECL_ARGUMENTS, TREE_CHAIN, TREE_TYPE, and variably_modified_type_p().
Referenced by create_nesting_tree().
| static void convert_all_function_calls | ( | struct nesting_info * | root | ) | [static] |
Definition at line 1274 of file tree-nested.c.
References nesting_info::chain_decl, nesting_info::chain_field, nesting_info::context, convert_call_expr(), convert_tramp_reference(), DECL_NO_STATIC_CHAIN, gcc_assert, nesting_info::inner, nesting_info::next, nesting_info::outer, and walk_function().
Referenced by lower_nested_functions().
Definition at line 1236 of file tree-nested.c.
References decl_function_context(), DECL_NO_STATIC_CHAIN, get_callee_fndecl(), get_static_chain(), info, walk_stmt_info::info, NULL_TREE, TREE_CODE, TREE_OPERAND, and walk_stmt_info::tsi.
Referenced by convert_all_function_calls().
Definition at line 929 of file tree-nested.c.
References walk_stmt_info::changed, nesting_info::context, current_function_decl, DECL_EXTERNAL, decl_function_context(), nesting_info::frame_decl, get_frame_field(), handled_component_p(), info, walk_stmt_info::info, init_tmp_var(), walk_stmt_info::is_lhs, IS_TYPE_OR_DECL_P, lookup_field_for_decl(), NO_INSERT, NULL, NULL_TREE, recompute_tree_invarant_for_addr_expr(), save_tmp_var(), TREE_ADDRESSABLE, TREE_CODE, TREE_OPERAND, TREE_STATIC, walk_stmt_info::tsi, tsi_gimplify_val(), use_pointer_in_frame(), walk_stmt_info::val_only, walk_tree(), and x.
Referenced by lower_nested_functions().
Definition at line 1122 of file tree-nested.c.
References block_may_fallthru(), build1, htab_find(), info, walk_stmt_info::info, LABEL_EXPR_LABEL, var_map_elt::new, new_label, NULL_TREE, var_map_elt::old, TREE_CODE, walk_stmt_info::tsi, tsi_end_p(), tsi_link_before(), tsi_prev(), TSI_SAME_STMT, tsi_stmt(), nesting_info::var_map, void_type_node, and x.
Referenced by lower_nested_functions().
Definition at line 1060 of file tree-nested.c.
References build_addr(), build_function_call_expr(), nesting_info::context, create_artificial_label(), decl_function_context(), DECL_NONLOCAL, EXPR_LOCUS, get_frame_field(), get_nl_goto_field(), GOTO_DESTINATION, htab_find_slot(), i, implicit_built_in_decls, info, walk_stmt_info::info, INSERT, var_map_elt::new, new_label, NULL, NULL_TREE, var_map_elt::old, nesting_info::outer, SET_EXPR_LOCUS, TREE_CODE, tree_cons, walk_stmt_info::tsi, tsi_gimplify_val(), tsi_stmt(), tsi_stmt_ptr(), x, and xmalloc().
Referenced by lower_nested_functions().
Definition at line 784 of file tree-nested.c.
References build1, walk_stmt_info::changed, nesting_info::context, DECL_EXTERNAL, decl_function_context(), FORCED_LABEL, get_frame_field(), GOTO_DESTINATION, handled_component_p(), i, info, walk_stmt_info::info, init_tmp_var(), INSERT, walk_stmt_info::is_lhs, IS_TYPE_OR_DECL_P, lookup_field_for_decl(), NULL, NULL_TREE, nesting_info::outer, recompute_tree_invarant_for_addr_expr(), save_tmp_var(), TREE_CODE, TREE_OPERAND, TREE_STATIC, TREE_TYPE, walk_stmt_info::tsi, tsi_gimplify_val(), use_pointer_in_frame(), walk_stmt_info::val_only, walk_tree(), and x.
Referenced by lower_nested_functions().
Definition at line 1161 of file tree-nested.c.
References build1, build_addr(), build_function_call_expr(), decl_function_context(), DECL_NO_STATIC_CHAIN, get_frame_field(), i, implicit_built_in_decls, info, walk_stmt_info::info, init_tmp_var(), INSERT, IS_TYPE_OR_DECL_P, lookup_tramp_for_decl(), NULL, NULL_TREE, TREE_CODE, tree_cons, TREE_OPERAND, TREE_TYPE, walk_stmt_info::tsi, tsi_gimplify_val(), walk_tree(), and x.
Referenced by convert_all_function_calls().
| static struct nesting_info* create_nesting_tree | ( | struct cgraph_node * | cgn | ) | [static, read] |
Definition at line 685 of file tree-nested.c.
References check_for_nested_with_variably_modified(), nesting_info::context, DECL_UNINLINABLE, free(), htab_create(), info, nesting_info::inner, nesting_info::next, nesting_info::outer, sub, nesting_info::var_map, var_map_eq(), var_map_hash(), and xcalloc().
Referenced by lower_nested_functions().
| static tree create_tmp_var_for | ( | struct nesting_info * | info, | |
| tree | type, | |||
| const char * | prefix | |||
| ) | [static] |
Definition at line 131 of file tree-nested.c.
References nesting_info::context, create_tmp_var_raw(), DECL_CONTEXT, DECL_SEEN_IN_BIND_EXPR_P, gcc_assert, nesting_info::new_local_var_chain, TREE_ADDRESSABLE, TREE_CHAIN, TREE_CODE, and TYPE_SIZE_UNIT.
Referenced by get_frame_type(), init_tmp_var(), and save_tmp_var().
| static void finalize_nesting_tree | ( | struct nesting_info * | root | ) | [static] |
Definition at line 1429 of file tree-nested.c.
References finalize_nesting_tree_1(), nesting_info::inner, and nesting_info::next.
Referenced by lower_nested_functions().
| static void finalize_nesting_tree_1 | ( | struct nesting_info * | root | ) | [static] |
Definition at line 1301 of file tree-nested.c.
References annotate_all_with_locus(), nesting_info::any_parm_remapped, nesting_info::any_tramp_created, append_to_statement_list(), BIND_EXPR_BODY, build(), build_addr(), build_function_call_expr(), cgraph_finalize_function(), cgraph_node(), cgraph_unnest_node(), nesting_info::chain_decl, nesting_info::chain_field, nesting_info::context, DECL_ARGUMENTS, DECL_NO_STATIC_CHAIN, DECL_SAVED_TREE, DECL_SOURCE_LOCATION, DECL_STRUCT_FUNCTION, declare_tmp_vars(), dump_function(), nesting_info::frame_decl, nesting_info::frame_type, function, get_chain_decl(), get_frame_field(), i, implicit_built_in_decls, nesting_info::inner, layout_decl(), layout_type(), lookup_field_for_decl(), lookup_tramp_for_decl(), nesting_info::new_local_var_chain, nesting_info::next, nesting_info::nl_goto_field, NO_INSERT, node, NULL, null_pointer_node, NULL_TREE, p, TDI_nested, TREE_CHAIN, tree_cons, TREE_TYPE, use_pointer_in_frame(), x, and is::y.
Referenced by finalize_nesting_tree().
| static void free_nesting_tree | ( | struct nesting_info * | root | ) | [static] |
Definition at line 1444 of file tree-nested.c.
References free(), htab_delete(), nesting_info::inner, nesting_info::next, next, and nesting_info::var_map.
Referenced by lower_nested_functions().
| static tree get_chain_decl | ( | struct nesting_info * | info | ) | [static] |
Definition at line 295 of file tree-nested.c.
References build_decl, build_pointer_type(), nesting_info::chain_decl, nesting_info::context, create_tmp_var_name(), DECL_ARG_TYPE, DECL_ARTIFICIAL, DECL_CONTEXT, DECL_IGNORED_P, get_frame_type(), nesting_info::outer, TREE_READONLY, and TREE_USED.
Referenced by finalize_nesting_tree_1(), get_frame_field(), and get_static_chain().
| static tree get_chain_field | ( | struct nesting_info * | info | ) | [static] |
Definition at line 332 of file tree-nested.c.
References build_pointer_type(), nesting_info::chain_field, DECL_ALIGN, DECL_NAME, DECL_NONADDRESSABLE_P, get_frame_type(), get_identifier(), insert_field_into_struct(), make_node, nesting_info::outer, TREE_TYPE, and TYPE_ALIGN.
Referenced by get_frame_field(), and get_static_chain().
| static tree get_frame_field | ( | struct nesting_info * | info, | |
| tree | target_context, | |||
| tree | field, | |||
| tree_stmt_iterator * | tsi | |||
| ) | [static] |
Definition at line 743 of file tree-nested.c.
References build(), build1, nesting_info::context, nesting_info::frame_decl, get_chain_decl(), get_chain_field(), get_frame_type(), i, init_tmp_var(), NULL_TREE, nesting_info::outer, TREE_TYPE, void, and x.
Referenced by convert_local_reference(), convert_nl_goto_reference(), convert_nonlocal_reference(), convert_tramp_reference(), and finalize_nesting_tree_1().
| static tree get_frame_type | ( | struct nesting_info * | info | ) | [static] |
Definition at line 192 of file tree-nested.c.
References concat(), nesting_info::context, create_tmp_var_for(), DECL_NAME, nesting_info::frame_decl, nesting_info::frame_type, free(), get_identifier(), IDENTIFIER_POINTER, make_node, NULL, and TYPE_NAME.
Referenced by get_chain_decl(), get_chain_field(), get_frame_field(), get_nl_goto_field(), lookup_field_for_decl(), and lookup_tramp_for_decl().
| static tree get_nl_goto_field | ( | struct nesting_info * | info | ) | [static] |
Definition at line 481 of file tree-nested.c.
References build_array_type(), build_index_type(), build_int_cst(), DECL_ALIGN, DECL_NAME, get_frame_type(), get_identifier(), GET_MODE_SIZE, insert_field_into_struct(), make_node, nesting_info::nl_goto_field, NULL_TREE, Pmode, ptr_mode, ptr_type_node, SAVE_NONLOCAL, size, STACK_SAVEAREA_MODE, TREE_ADDRESSABLE, TREE_TYPE, and TYPE_ALIGN.
Referenced by convert_nl_goto_reference().
| static tree get_static_chain | ( | struct nesting_info * | info, | |
| tree | target_context, | |||
| tree_stmt_iterator * | tsi | |||
| ) | [static] |
Definition at line 711 of file tree-nested.c.
References build(), build1, build_addr(), nesting_info::context, nesting_info::frame_decl, get_chain_decl(), get_chain_field(), i, init_tmp_var(), NULL_TREE, nesting_info::outer, TREE_TYPE, and x.
Referenced by convert_call_expr().
| static GTY | ( | () | ) | [static] |
Definition at line 398 of file tree-nested.c.
References align, BITS_PER_UNIT, build_array_type(), build_decl, build_index_type(), build_int_cst(), char_type_node, DECL_ALIGN, DECL_USER_ALIGN, get_identifier(), layout_type(), make_node, NULL_TREE, size, STACK_BOUNDARY, TRAMPOLINE_ALIGNMENT, TRAMPOLINE_SIZE, TYPE_FIELDS, and TYPE_NAME.
| static tree init_tmp_var | ( | struct nesting_info * | info, | |
| tree | exp, | |||
| tree_stmt_iterator * | tsi | |||
| ) | [static] |
Definition at line 356 of file tree-nested.c.
References build(), create_tmp_var_for(), EXPR_LOCUS, NULL, SET_EXPR_LOCUS, TREE_TYPE, tsi_link_before(), TSI_SAME_STMT, and tsi_stmt().
Referenced by convert_local_reference(), convert_nonlocal_reference(), convert_tramp_reference(), get_frame_field(), get_static_chain(), lower_omp_1(), and tsi_gimplify_val().
Definition at line 170 of file tree-nested.c.
References DECL_ALIGN, DECL_CONTEXT, p, TREE_CHAIN, and TYPE_FIELDS.
Referenced by get_chain_field(), get_nl_goto_field(), install_var_field(), lookup_field_for_decl(), and lookup_tramp_for_decl().
| static tree lookup_field_for_decl | ( | struct nesting_info * | info, | |
| tree | decl, | |||
| enum insert_option | insert | |||
| ) | [static] |
Definition at line 237 of file tree-nested.c.
References nesting_info::any_parm_remapped, build_pointer_type(), DECL_ALIGN, DECL_NAME, DECL_NONADDRESSABLE_P, DECL_SOURCE_LOCATION, DECL_USER_ALIGN, gcc_assert, get_frame_type(), htab_find_slot(), INSERT, insert_field_into_struct(), make_node, var_map_elt::new, NULL, var_map_elt::old, TREE_ADDRESSABLE, TREE_CODE, TREE_THIS_VOLATILE, TREE_TYPE, TYPE_ALIGN, use_pointer_in_frame(), nesting_info::var_map, and xmalloc().
Referenced by convert_local_reference(), convert_nonlocal_reference(), and finalize_nesting_tree_1().
| static tree lookup_tramp_for_decl | ( | struct nesting_info * | info, | |
| tree | decl, | |||
| enum insert_option | insert | |||
| ) | [static] |
Definition at line 438 of file tree-nested.c.
References nesting_info::any_tramp_created, DECL_NAME, gcc_assert, get_frame_type(), htab_find_slot(), INSERT, insert_field_into_struct(), make_node, var_map_elt::new, NULL, var_map_elt::old, TREE_ADDRESSABLE, TREE_TYPE, nesting_info::var_map, and xmalloc().
Referenced by convert_tramp_reference(), and finalize_nesting_tree_1().
Definition at line 1463 of file tree-nested.c.
References cgraph_node(), convert_all_function_calls(), convert_local_reference(), convert_nl_goto_receiver(), convert_nl_goto_reference(), convert_nonlocal_reference(), create_nesting_tree(), finalize_nesting_tree(), free_nesting_tree(), root, and walk_all_functions().
Referenced by cgraph_finalize_function().
| static tree save_tmp_var | ( | struct nesting_info * | info, | |
| tree | exp, | |||
| tree_stmt_iterator * | tsi | |||
| ) | [static] |
Definition at line 383 of file tree-nested.c.
References build(), create_tmp_var_for(), EXPR_LOCUS, NULL, SET_EXPR_LOCUS, TREE_TYPE, tsi_link_after(), TSI_SAME_STMT, and tsi_stmt().
Referenced by convert_local_reference(), convert_nonlocal_reference(), and lower_omp_1().
| static tree tsi_gimplify_val | ( | struct nesting_info * | info, | |
| tree | exp, | |||
| tree_stmt_iterator * | tsi | |||
| ) | [static] |
Definition at line 371 of file tree-nested.c.
References init_tmp_var(), and is_gimple_val().
Referenced by convert_local_reference(), convert_nl_goto_reference(), convert_nonlocal_reference(), and convert_tramp_reference().
Definition at line 217 of file tree-nested.c.
References AGGREGATE_TYPE_P, DECL_SIZE, NULL, TREE_CODE, TREE_CONSTANT, and TREE_TYPE.
Referenced by convert_local_reference(), convert_nonlocal_reference(), finalize_nesting_tree_1(), and lookup_field_for_decl().
Definition at line 116 of file tree-nested.c.
References a, b, and var_map_elt::old.
Referenced by create_nesting_tree().
Definition at line 109 of file tree-nested.c.
References a, htab_hash_pointer, and var_map_elt::old.
Referenced by create_nesting_tree().
| static void walk_all_functions | ( | walk_tree_fn | callback, | |
| struct nesting_info * | root | |||
| ) | [static] |
Definition at line 627 of file tree-nested.c.
References nesting_info::inner, nesting_info::next, and walk_function().
Referenced by lower_nested_functions().
| static void walk_function | ( | walk_tree_fn | callback, | |
| struct nesting_info * | info | |||
| ) | [static] |
Definition at line 612 of file tree-nested.c.
References walk_stmt_info::callback, nesting_info::context, DECL_SAVED_TREE, walk_stmt_info::info, memset, walk_stmt_info::val_only, and walk_stmts().
Referenced by convert_all_function_calls(), and walk_all_functions().
| static void walk_stmts | ( | struct walk_stmt_info * | wi, | |
| tree * | tp | |||
| ) | [static] |
Definition at line 544 of file tree-nested.c.
References BIND_EXPR_BODY, walk_stmt_info::callback, CATCH_BODY, COND_EXPR_COND, COND_EXPR_ELSE, COND_EXPR_THEN, EH_FILTER_FAILURE, i, is_gimple_formal_tmp_var(), is_gimple_mem_rhs(), walk_stmt_info::is_lhs, NULL, TREE_CODE, TREE_OPERAND, walk_stmt_info::tsi, tsi_end_p(), tsi_next(), tsi_start(), tsi_stmt_ptr(), walk_stmt_info::val_only, and walk_tree().
Referenced by diagnose_omp_structured_block_errors(), diagnose_sb_1(), diagnose_sb_2(), lower_omp(), scan_omp(), and walk_function().
1.5.6