This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa-branch]: Patch for misc things
- From: Diego Novillo <dnovillo at redhat dot com>
- To: Daniel Berlin <dberlin at dberlin dot org>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Thu, 8 Aug 2002 21:00:13 -0400
- Subject: Re: [tree-ssa-branch]: Patch for misc things
- Organization: Red Hat Canada
- References: <Pine.LNX.4.44.0208081641400.3593-100000@dberlin.org>
On Thu, 08 Aug 2002, Daniel Berlin wrote:
> Fixes a few things, adds the find_expr_in_tree change we talked about.
>
I'll recap for the benefit of the list:
- find_expr_in_tree should also be allowed to follow
TREE_CHAINs for statements within a single scope.
- To do this, we pass a recursion level argument.
- Inserting before a FOR_EXPR didn't work because
find_first_exec_stmt was not doing the right thing.
Is that about right?
> 2002-08-08 Daniel Berlin <dberlin@dberlin.org>
>
> * tree-cfg.c (find_expr_in_tree_helper): Renamed from find_expr_in_tree.
> (find_expr_in_tree): Redone.
>
You know. I've been thinking about this today. This function is
remarkably similar to walk_tree. I think it would be better to
re-implement it as a callback for walk_tree. But this is OK for
now.
Frankly, I'd like to shred insert_* and re-write them from
scratch.
> 2002-07-30 Daniel Berlin <dberlin@dberlin.org>
>
> * tree-cfg.c (insert_before_ctrl_stmt): Fix insertion for various
> parts of for loop.
>
> * tree-ssa-pre.c (finalize_1): Set EXPR_STMT type to type of
> expression in it.
>
Patch doesn't apply in my tree, but it looks OK.
> ! static tree *
> ! find_expr_in_tree_helper (t, expr, level, substate)
> tree t;
> tree expr;
> + int level;
> + bool substate;
>
Document what 'level' and 'substate' mean, please.
Diego.