This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] RFC: Making control flow more explicit
Hello,
> > I am not really sure what is the exact meaning of the parent. Can't you
> > run into problems in cases like
> >
> > if (c1)
> > goto bla;
> >
> > if (c2)
> > {
> > something;
> > bla:
> > something_else;
> > }
> > ?
> >
> You shouldn't. What would be the dead statement here?
sorry, I did not really think about what I write into the example.
What I wanted to point out is that with presence of gotos "parent"
loses sense, so it has to be handled somehow anyway (or if it is not,
something is wrong).
> > Anyway, losing concept of parent relationship seems to be relatively
> > small cost in comparison to other gains.
> >
> The only reason why we use the parent relation is to avoid spending time
> building the control dependence information. That can be costly. IIRC,
> Jeff Law had done some experiments with that, but they don't seem to be
> in CVS.
It should not be; it is just some playing with dominators and
post-dominators, isn't it? Note that the problem might be just that
our current implementation of dominator tree is not very efficient
(although using et-trees seemed like a cool idea to me originally :-(
Zdenek