RESOLVED FIXED 66921
[CSSRegions] RenderFlowThread::renderRegionForLine should use a faster search method
https://bugs.webkit.org/show_bug.cgi?id=66921
Summary [CSSRegions] RenderFlowThread::renderRegionForLine should use a faster search...
Alexandru Chiculita
Reported 2011-08-24 23:17:47 PDT
The RenderRegion rects are always in order. There should be a faster way to search the region at a specified position.
Attachments
A sample from a client, that might prove to be a good test-case for this. Addmitedly, the algorithm is (very) naive, but it shouldn't take 5 minutes to finish, nonetheless. (19.80 KB, application/x-zip-compressed)
2012-08-16 09:36 PDT, Mihai Balan
no flags
Patch (9.54 KB, patch)
2013-04-03 08:38 PDT, Andrei Bucur
no flags
Patch (9.56 KB, patch)
2013-04-03 09:33 PDT, Andrei Bucur
no flags
Radar WebKit Bug Importer
Comment 1 2011-09-30 16:08:38 PDT
Mihai Balan
Comment 2 2012-08-16 09:36:17 PDT
Created attachment 158840 [details] A sample from a client, that might prove to be a good test-case for this. Addmitedly, the algorithm is (very) naive, but it shouldn't take 5 minutes to finish, nonetheless.
Andrei Bucur
Comment 3 2013-04-03 08:38:58 PDT
Andrei Bucur
Comment 4 2013-04-03 08:40:52 PDT
Comment on attachment 196358 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=196358&action=review > Source/WebCore/rendering/RenderFlowThread.cpp:968 > + if (interval.data()->isRenderRegionSet()) Is it possible we'd want to return a region set that's not the last region? The old code seemed to have allowed it.
Dave Hyatt
Comment 5 2013-04-03 08:49:13 PDT
Comment on attachment 196358 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=196358&action=review Please handle expandToEncompassFlowThreadContentsIfNeeded() which hacks the flow thread portion rect. You'll want to make sure that interval gets correctly updated. > Source/WebCore/rendering/RenderFlowThread.cpp:827 > + m_regionIntervalTree.add(RegionIntervalTree::createInterval(regionRect.y(), regionRect.maxY(), region)); I think because of writing modes it would read better not to use y() and maxY() here. You could just use logicalHeight and logicalHeight + regionLogicalHeight, and I think that would read slightly better. >> Source/WebCore/rendering/RenderFlowThread.cpp:968 >> + if (interval.data()->isRenderRegionSet()) > > Is it possible we'd want to return a region set that's not the last region? The old code seemed to have allowed it. Yes, it will be possible to have multiple region sets. Your code is going to be applicable to region sets.
Andrei Bucur
Comment 6 2013-04-03 09:33:25 PDT
Dave Hyatt
Comment 7 2013-04-03 12:38:52 PDT
Comment on attachment 196363 [details] Patch r=me
WebKit Review Bot
Comment 8 2013-04-04 04:08:44 PDT
Comment on attachment 196363 [details] Patch Clearing flags on attachment: 196363 Committed r147620: <http://trac.webkit.org/changeset/147620>
WebKit Review Bot
Comment 9 2013-04-04 04:08:49 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.