Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upDo a sequential traversal to perform the block formatting context speculation #7551
Comments
|
This is already done. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Unfortunately I think we'll need to do a special sequential traversal in order to correctly handle the speculation for block formatting contexts next to floats. The reason is that it's not enough to look at your immediate children to correctly figure out the widths of floats next to you, because of the way clear and float are inherently in-order. The lack of this causes the infobox on Google.com SERPs to run into the floats. This traversal should hopefully be pretty quick, because all it has to do is to sum up preferred widths. It should be restricted to the subtrees that involve block formatting contexts next to floats.
We should figure out how to restrict the size of this subtree and measure the performance cost of this traversal carefully, because it has the potential to jeopardize our parallel layout gains due to Amdahl's Law. Another alternative if this traversal turns out to be too slow would be to just stick with the speculation we have and implement the sequential fallback when the speculation fails.