Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
layout: Rewrite display list building to be parallel and to handle
overflow correctly, and opportunistically lay out blocks in parallel even if floats are present. This commit fixes the `inline-height-test` in Acid2 by implementing proper overflow as well as the inline "strut". (See CSS 2.1 § 10.8.1.) Acid2 was accidentally being rendered properly before because tables' descendant flows were not being laid out properly. Display list building is now parallel and is done by bubbling up display items and layers from parent to child. Speedups of around 60%-70% are observed on Wikipedia with a 4-core HyperThreaded Core i7. More optimizations are possible; this is just a start. To minimize the amount of data that needs to be bubbled up, as well as to make proper handling of `overflow: hidden` clipping easier, the `StackingContext` abstraction is now purely internal to the display list. That is, instead of placing items into a stacking context directly, display items are placed into display lists alongside a stacking level. When a stacking context is complete, it is flattened with the the `flatten` method, which shuffles the display items that make up the context into their proper order while handling clipping properly.
- Loading branch information
81f5da9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=larsbergstrom