Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to trunk. Richard.
2012-03-29 Richard Guenther <rguent...@suse.de> * tree-flow.h (struct pre_expr_d): Remove forward declaration. (add_to_value): Remove. (print_value_expressions): Likewise. * tree-ssa-pre.c (add_to_value): Make static. (print_value_expressions): Likewise. * gimple.h (gimple_adjust_this_by_delta): Remove. * gimple-fold.c (gimple_adjust_this_by_delta): Likewise. Index: gcc/tree-flow.h =================================================================== *** gcc/tree-flow.h (revision 185918) --- gcc/tree-flow.h (working copy) *************** extern bool verify_eh_dispatch_edge (gim *** 794,803 **** extern void maybe_remove_unreachable_handlers (void); /* In tree-ssa-pre.c */ - struct pre_expr_d; - void add_to_value (unsigned int, struct pre_expr_d *); void debug_value_expressions (unsigned int); - void print_value_expressions (FILE *, unsigned int); /* In tree-ssa-sink.c */ bool is_hidden_global_store (gimple); --- 794,800 ---- Index: gcc/tree-ssa-pre.c =================================================================== *** gcc/tree-ssa-pre.c (revision 185918) --- gcc/tree-ssa-pre.c (working copy) *************** phi_trans_add (pre_expr e, pre_expr v, b *** 587,593 **** /* Add expression E to the expression set of value id V. */ ! void add_to_value (unsigned int v, pre_expr e) { bitmap_set_t set; --- 587,593 ---- /* Add expression E to the expression set of value id V. */ ! static void add_to_value (unsigned int v, pre_expr e) { bitmap_set_t set; *************** debug_bitmap_set (bitmap_set_t set) *** 1031,1037 **** /* Print out the expressions that have VAL to OUTFILE. */ ! void print_value_expressions (FILE *outfile, unsigned int val) { bitmap_set_t set = VEC_index (bitmap_set_t, value_expressions, val); --- 1031,1037 ---- /* Print out the expressions that have VAL to OUTFILE. */ ! static void print_value_expressions (FILE *outfile, unsigned int val) { bitmap_set_t set = VEC_index (bitmap_set_t, value_expressions, val); Index: gcc/gimple.h =================================================================== *** gcc/gimple.h (revision 185918) --- gcc/gimple.h (working copy) *************** unsigned get_gimple_rhs_num_ops (enum tr *** 960,966 **** gimple gimple_alloc_stat (enum gimple_code, unsigned MEM_STAT_DECL); const char *gimple_decl_printable_name (tree, int); tree gimple_get_virt_method_for_binfo (HOST_WIDE_INT, tree); - void gimple_adjust_this_by_delta (gimple_stmt_iterator *, tree); tree gimple_extract_devirt_binfo_from_cst (tree); /* Returns true iff T is a valid GIMPLE statement. */ extern bool is_gimple_stmt (tree); --- 960,965 ---- Index: gcc/gimple-fold.c =================================================================== *** gcc/gimple-fold.c (revision 185918) --- gcc/gimple-fold.c (working copy) *************** gimple_fold_builtin (gimple stmt) *** 978,1006 **** return result; } - /* Generate code adjusting the first parameter of a call statement determined - by GSI by DELTA. */ - - void - gimple_adjust_this_by_delta (gimple_stmt_iterator *gsi, tree delta) - { - gimple call_stmt = gsi_stmt (*gsi); - tree parm, tmp; - gimple new_stmt; - - delta = convert_to_ptrofftype (delta); - gcc_assert (gimple_call_num_args (call_stmt) >= 1); - parm = gimple_call_arg (call_stmt, 0); - gcc_assert (POINTER_TYPE_P (TREE_TYPE (parm))); - tmp = create_tmp_var (TREE_TYPE (parm), NULL); - add_referenced_var (tmp); - - tmp = make_ssa_name (tmp, NULL); - new_stmt = gimple_build_assign_with_ops (POINTER_PLUS_EXPR, tmp, parm, delta); - SSA_NAME_DEF_STMT (tmp) = new_stmt; - gsi_insert_before (gsi, new_stmt, GSI_SAME_STMT); - gimple_call_set_arg (call_stmt, 0, tmp); - } /* Return a binfo to be used for devirtualization of calls based on an object represented by a declaration (i.e. a global or automatically allocated one) --- 978,983 ----