This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] tree-ssa-sink.c: Don't restrict immediate uses that weconsider.
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: Kazu Hirata <kazu at cs dot umass dot edu>
- Cc: gcc-patches at gcc dot gnu dot org, law at redhat dot com
- Date: Thu, 07 Apr 2005 12:19:33 -0400
- Subject: Re: [patch] tree-ssa-sink.c: Don't restrict immediate uses that weconsider.
- References: <20050407.103723.133895356.kazu@cs.umass.edu>
On Thu, 2005-04-07 at 10:37 -0400, Kazu Hirata wrote:
> Hi,
>
> Attached is a patch to teach nearest_common_dominator_of_uses not to
> restrict the set of immediate uses that we consider.
>
> nearest_common_dominator_of_uses goes through immediate uses to find a
> location to sink a statement into. It's important that we consider
> all uses so that whatever location we come with dominates all uses.
> It's dangerous to have an "if" statement to restrict the set of
> immediate uses that we consider like so
>
> if (PHI_ARG_DEF (usestmt, idx) == var)
>
> because the location that we come up with may not dominate all uses.
>
You were the one who just added thi. :)
So doesn't this effectively just undo the patch you had come up with?