[LayoutNG] Improve handling of many floats within one single FC.
This patch improves the performance of lots of floats within a single formatting context. Previously when we built the DerivedGeometry (the data-structure used for querying information), we naively placed all floats into this data-structure (which is relatively expensive to build). This introduced a performance regression in the site within crbug.com/1081477 . This patch introduces a "ceiling" for the DerivedGeometry class, that is the highest block-offset it is used to answer queries for. It is extremely rare to go "backwards" and query for something higher than what we've just created. This is used to only all floats below this ceiling substantially reducing the cost of building the DerivedGeometry. Added floats_show_hide.html which has improved 50% locally. On the real world site there is approx. a 20x improvement. Bug: 1081477 Change-Id: I7b3ced903e2218f13a852bb6487271afd50d30d8 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2313476 Commit-Queue: Ian Kilpatrick <ikilpatrick@chromium.org> Reviewed-by:Christian Biesinger <cbiesinger@chromium.org> Reviewed-by:
Koji Ishii <kojii@chromium.org> Cr-Commit-Position: refs/heads/master@{#791655}
Showing
Please register or sign in to comment