diff options
author | Andrew Pinski <pinskia@gcc.gnu.org> | 2004-11-19 10:21:44 -0800 |
---|---|---|
committer | Andrew Pinski <pinskia@gcc.gnu.org> | 2004-11-19 10:21:44 -0800 |
commit | 3a2e4b46f56c32ab31a482b6ffbe545e8cbfefd0 (patch) | |
tree | cef3e7dc682cfc4ccf35d090d8831c64c6f3c3ce /gcc/tree-flow.h | |
parent | 0e1ad529d715d705d1d4f8dbc188a52a3a570637 (diff) | |
download | gcc-3a2e4b46f56c32ab31a482b6ffbe545e8cbfefd0.zip gcc-3a2e4b46f56c32ab31a482b6ffbe545e8cbfefd0.tar.gz gcc-3a2e4b46f56c32ab31a482b6ffbe545e8cbfefd0.tar.bz2 |
re PR tree-optimization/18507 (block_defs_stack varrray should not be GC'ed)
2004-11-19 Andrew Pinski <pinskia@physics.uc.edu>
PR tree-opt/18507
* tree-flow.h (tree2): Typedef because there is already a VEC(tree).
Define a VEC(tree2) for head.
(register_new_def): Change second argument to be a VEC(tree2).
* tree-ssa-dom.c (block_defs_stack): Change to be a VEC(tree2).
(tree_ssa_dominator_optimize): Initialize block_defs_stack with
the VEC(tree2) function. Also free it before returning.
(dom_opt_initialize_block): Use VEC_safe_push instead of VARRAY_PUSH_TREE
for block_defs_stack.
(restore_currdefs_to_original_value): Use VEC_length instead of
VARRAY_ACTIVE_SIZE. VEC_pop instead of VARRAY_TOP_TREE/VARRAY_POP.
(dom_opt_finalize_block): Use VEC_safe_push instead of VARRAY_PUSH_TREE
for block_defs_stack.
* tree-into-ssa.c (block_defs_stack): Change to be a VEC(tree2).
(rewrite_initialize_block): Use VEC_safe_push instead of VARRAY_PUSH_TREE
for block_defs_stack.
(ssa_register_new_def): Likewise.
(ssa_rewrite_initialize_block): Likewise.
(rewrite_finalize_block): Use VEC_length instead of
VARRAY_ACTIVE_SIZE. VEC_pop instead of VARRAY_TOP_TREE/VARRAY_POP.
(ssa_rewrite_finalize_block): Likewise.
(register_new_def): Change second argument to be a VEC(tree2).
Use VEC_safe_push instead of VARRAY_PUSH_TREE.
(rewrite_blocks): Initialize block_defs_stack with
the VEC(tree2) function. Also free it before returning.
(rewrite_ssa_into_ssa): Likewise.
From-SVN: r90926
Diffstat (limited to 'gcc/tree-flow.h')
-rw-r--r-- | gcc/tree-flow.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/tree-flow.h b/gcc/tree-flow.h index e392ddc..da68b32 100644 --- a/gcc/tree-flow.h +++ b/gcc/tree-flow.h @@ -562,6 +562,9 @@ extern struct ptr_info_def *get_ptr_info (tree); definition, a function with this prototype is called. */ typedef bool (*walk_use_def_chains_fn) (tree, tree, void *); +typedef tree tree_on_heap; +DEF_VEC_MALLOC_P (tree_on_heap); + /* In tree-ssa.c */ extern void init_tree_ssa (void); extern void debug_reaching_defs (void); @@ -577,7 +580,7 @@ extern bool tree_ssa_useless_type_conversion (tree); extern bool tree_ssa_useless_type_conversion_1 (tree, tree); extern void verify_ssa (void); extern void delete_tree_ssa (void); -extern void register_new_def (tree, varray_type *); +extern void register_new_def (tree, VEC (tree_on_heap) **); extern void walk_use_def_chains (tree, walk_use_def_chains_fn, void *, bool); extern void kill_redundant_phi_nodes (void); extern bool stmt_references_memory_p (tree); |