[Webkit-unassigned] [Bug 80415] Eliminate redundant Phis in DFG
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Mar 6 17:43:22 PST 2012
https://bugs.webkit.org/show_bug.cgi?id=80415
--- Comment #10 from Filip Pizlo <fpizlo at apple.com> 2012-03-06 17:43:22 PST ---
(In reply to comment #9)
> (In reply to comment #7)
> > >
> > > No, I haven't tried it - I was just worried that traversing the whole graph for Phi replacement may be time consuming especially when the traversal can be iterative. We can try it and I think we should only need the iterative traversal on the Phi nodes (if we have the fix of bug 80361 it would be easier) and a one-time traversal on other nodes in the graph (actually, at current stage, the GetLocals) after all of the Phi replacements are identified.
> >
> > It seems like one way around this is to just track the Phis, and not the Phi uses.
> >
> > We can first do a fixpoint where we simplify Phis only - which may leave dummy Phis like:
> >
> > somePhi: Phi(@something)
> >
> > where @something is either another Phi or something real (like a SetLocal), and somePhi is still referenced from various other places (GetLocal, etc).
> >
> > Then we can do a second pass that considers all nodes (not just Phis) and checks if those nodes reference trivial Phis. If they do, then replace.
> >
> > I think that this should be sufficient, since the fixpoint (as I understand it) only depends on the shape of Phis and not the shapes of users of Phis. So you only need to visit Phis repeatedly - and after that you can visit all non-Phi uses of Phis in one go.
> >
> > Would that work?
>
> Yes. I think that's exactly what I mean for "iterative traversal on the Phi nodes only" at first and then "one-time traversal on other nodes in the graph". - if I understand you correctly. :)
Ooops, sorry, yes, we're thinking the same thing. :-) I didn't read carefully enough the first time.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list