aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-operands.h
diff options
context:
space:
mode:
authorDaniel Berlin <dberlin@dberlin.org>2007-06-30 14:15:26 +0000
committerDaniel Berlin <dberlin@gcc.gnu.org>2007-06-30 14:15:26 +0000
commit89fb70a345104a84bff4d5105f3456e7b8a5ca1e (patch)
tree3d5f6f46e5be067510e255315be8197a985346ee /gcc/tree-ssa-operands.h
parent11147af3976574211dce0f0d69d2566f03b79c14 (diff)
downloadgcc-89fb70a345104a84bff4d5105f3456e7b8a5ca1e.zip
gcc-89fb70a345104a84bff4d5105f3456e7b8a5ca1e.tar.gz
gcc-89fb70a345104a84bff4d5105f3456e7b8a5ca1e.tar.bz2
Fix PR tree-optimization/32540 Fix PR tree-optimization/31651
2007-06-30 Daniel Berlin <dberlin@dberlin.org> Fix PR tree-optimization/32540 Fix PR tree-optimization/31651 * tree-ssa-sccvn.c: New file. * tree-ssa-sccvn.h: Ditto. * tree-vn.c: Include tree-ssa-sccvn.h (val_expr_paid_d): Removed. (value_table): Ditto. (vn_compute): Ditto. (val_expr_pair_hash): Ditto. (val_expr_pair_expr_eq): Ditto. (copy_vuses_from_stmt): Ditto. (vn_delete): Ditto. (vn_init): Ditto. (shared_vuses_from_stmt): Ditto. (print_creation_to_file): Moved up. (sort_vuses): Ditto. (sort_vuses_heap): Ditto. (set_value_handle): Make non-static. (make_value_handle): Ditto. (vn_add): Rewritten to use sccvn lookups. (vn_add_with_vuses): Ditto. (vn_lookup): Ditto (and second argument removed). (vn_lookup_with_vuses): Ditto. (vn_lookup_or_add): Ditto (and second argument removed); (vn_lookup_or_add_with_vuses): Ditto. (vn_lookup_with_stmt): New. (vn_lookup_or_add_with_stmt): Ditto. (create_value_handle_for_expr): Ditto. * tree-ssa-pre.c: Include tree-ssa-sccvn.h. (seen_during_translate): New function. (phi_trans_lookup): Use iterative_hash_expr, not vn_compute. (phi_trans_add): Ditto. (constant_expr_p): FIELD_DECL is always constant. (phi_translate_1): Renamed from phi_translate, add seen bitmap. Use constant_expr_p. Avoid infinite recursion on mutually valued expressions. Change callers of vn_lookup_or_add. (phi_translate): New function. (compute_antic_safe): Allow phi nodes. (create_component_ref_by_pieces): Update for FIELD_DECL change. (find_or_generate_expression): Rewrite slightly. (create_expression_by_pieces): Updated for vn_lookup_or_add change. Update VN_INFO for new names. (insert_into_preds_of_block): Update for new names. (add_to_exp_gen): New function. (add_to_sets): Use vn_lookup_or_add_with_stmt. (find_existing_value_expr): Rewrite to changed vn_lookup. (create_value_expr_from): Ditto, and use add_to_exp_gen. (try_look_through_load): Removed. (try_combine_conversion): Ditto. (get_sccvn_value): New function. (make_values_for_phi): Ditto. (make_values_for_stmt): Ditto. (compute_avail): Rewritten for vn_lookup_or_add changes and to use SCCVN. (init_pre): Update for SCCVN changes. (fini_pre): Ditto. (execute_pre): Ditto. * tree-flow.h (make_value_handle): Declare. (set_value_handle): Ditto. (sort_vuses_heap): Ditto. (vn_lookup_or_add_with_stmt): Ditto. (vn_lookup_with_stmt): Ditto. (vn_compute): Remove. (vn_init): Ditto. (vn_delete): Ditto. (vn_lookup): Update arguments. * Makefile.in (tree-ssa-pre.o): Add tree-ssa-sccvn.h (tree-vn.o): Ditto. (tree-ssa-sccvn.o): New. (OBJS-common): Add tree-ssa-sccvn.o From-SVN: r126149
Diffstat (limited to 'gcc/tree-ssa-operands.h')
-rw-r--r--gcc/tree-ssa-operands.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/tree-ssa-operands.h b/gcc/tree-ssa-operands.h
index 09b3b7b..b3f2cf0 100644
--- a/gcc/tree-ssa-operands.h
+++ b/gcc/tree-ssa-operands.h
@@ -299,12 +299,12 @@ typedef struct ssa_operand_iterator_d
DEFVAR = op_iter_next_def (&(ITER)))
/* This macro executes a loop over the VDEF operands of STMT. The def
- and use for each VDEF is returned in DEFVAR and USEVAR.
+ and use vector for each VDEF is returned in DEFVAR and USEVECT.
ITER is an ssa_op_iter structure used to control the loop. */
-#define FOR_EACH_SSA_VDEF_OPERAND(DEFVAR, USEVAR, STMT, ITER) \
- for (op_iter_init_vdef (&(ITER), STMT, &(USEVAR), &(DEFVAR)); \
+#define FOR_EACH_SSA_VDEF_OPERAND(DEFVAR, USEVECT, STMT, ITER) \
+ for (op_iter_init_vdef (&(ITER), STMT, &(USEVECT), &(DEFVAR)); \
!op_iter_done (&(ITER)); \
- op_iter_next_vdef (&(USEVAR), &(DEFVAR), &(ITER)))
+ op_iter_next_vdef (&(USEVECT), &(DEFVAR), &(ITER)))
/* This macro will execute a loop over all the arguments of a PHI which
match FLAGS. A use_operand_p is always returned via USEVAR. FLAGS