On 9/10/13 4:05 PM, Patrick Walton wrote:
Could we do the particular optimization that Chrome is doing in Servo by just threading "what part of layout are we interested in?" (the LayoutGoal in Servo terms) throughout layout and sending the answer over a channel as soon as we know it?
The hard-ish part is knowing when you know it.
For example, if we want offsetWidth of a div, then we could make the LayoutGoal something like "offsetWidth of div so-and-so" and then as soon as we know the answer send it to the content task. We would continue doing the layout as usual in the layout thread.
Or bail out of it, either way. For the use cases here bailing out would be better, since people tend to do this sort of thing in a loop.
But again, the hard part is knowing when you have a final value for the thing of interest.
-Boris _______________________________________________ dev-servo mailing list dev-servo@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-servo