This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH]: Fix latent bug in tailcall
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: Daniel Berlin <dberlin at dberlin dot org>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>, Diego Novillo <dnovillo at redhat dot com>
- Date: Tue, 31 Jan 2006 14:18:59 -0500
- Subject: Re: [PATCH]: Fix latent bug in tailcall
- References: <43DFB1E2.3070802@dberlin.org>
Daniel Berlin wrote:
> This patch fixes a latent bug in tree-tailcall where it did not update
> the virtual ssa form for non-call clobbered virtual operands, even when
> there were live on entry virtual operands that needed updating.
Just to be thorough for Diego (and the list)'s, you *could* do this
without calling update_ssa, but the algorithm used is the same:
For each virtual definition that has a live on entry operand
1. Find the definition that will now reach the entry block
and a dd this definition as a phi argument.
2. Add the live on entry definition as the other phi argument
3. Replace all uses to use the phi node.
I tried implementing this, and it ends up being no faster than calling
the virtuals-only update, so ......
--Dan