Bug 82928 - Optimizing tracking of intruding floats being removed from RenderBlock during layout
Summary: Optimizing tracking of intruding floats being removed from RenderBlock during...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Ken Buchanan
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-02 12:46 PDT by Ken Buchanan
Modified: 2012-04-13 17:38 PDT (History)
2 users (show)

See Also:


Attachments
Patch (2.30 KB, patch)
2012-04-12 11:45 PDT, Ken Buchanan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ken Buchanan 2012-04-02 12:46:12 PDT
This is a follow-up for bug 74056, for some performance improvements in special cases.

dhyatt's comment on https://bugs.webkit.org/show_bug.cgi?id=74056 --

> Not going to minus for this but thought of a couple of optimizations if you don't mind following up:
> 
> (1) If the oldIntrudingFloat set ever empties out, you can bail out of that last loop early.
> 
> In other words:
> 
> for (FloatingObjectSetIterator it = floatingObjectSet.begin(); it != end && !oldIntrudingFloatSet.isEmpty(); ++it)
>     oldIntrudingFloatSet.remove((*it)->m_renderer);
> 
> That way once the set gets emptied out, you don't waste time iterating over floats that you know won't be found in the set.
> 
> (2) If you cached an intruding object count and kept it up to date, you could really optimize the avoidsFloats case, since all it did was checked for if you had any intruding floats at all. Then you could make that case O(1) instead of O(n).
> 
> I won't minus, but I'd appreciate a follow-up bug and fixes for this.
Comment 1 Ken Buchanan 2012-04-12 11:45:24 PDT
Created attachment 136945 [details]
Patch
Comment 2 Dave Hyatt 2012-04-13 10:44:49 PDT
Comment on attachment 136945 [details]
Patch

r=me
Comment 3 WebKit Review Bot 2012-04-13 17:38:42 PDT
Comment on attachment 136945 [details]
Patch

Clearing flags on attachment: 136945

Committed r114190: <http://trac.webkit.org/changeset/114190>
Comment 4 WebKit Review Bot 2012-04-13 17:38:49 PDT
All reviewed patches have been landed.  Closing bug.