Bug 214312 - Drop cache of subframe count on the Page
Summary: Drop cache of subframe count on the Page
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Page Loading (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-07-14 12:06 PDT by Chris Dumez
Modified: 2020-07-14 22:44 PDT (History)
6 users (show)

See Also:


Attachments
Patch (7.66 KB, patch)
2020-07-14 12:37 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Patch (7.79 KB, patch)
2020-07-14 12:44 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2020-07-14 12:06:53 PDT
Drop cache of subframe count on the Page as it is error-prone to keep it up to date and it is not performance sensitive. We only need the subframe count when trying to load a new iframe to see if we reached the maximum number of subframes (1000). Calculating this count is also not very expensive since we merely need to iterate the frame tree, which is composed of at most 1000 frames.
Comment 1 Chris Dumez 2020-07-14 12:07:02 PDT
<rdar://problem/65433615>
Comment 2 Chris Dumez 2020-07-14 12:37:53 PDT
Created attachment 404265 [details]
Patch
Comment 3 Chris Dumez 2020-07-14 12:44:47 PDT
Created attachment 404267 [details]
Patch
Comment 4 Geoffrey Garen 2020-07-14 13:31:02 PDT
Comment on attachment 404267 [details]
Patch

r=me
Comment 5 Geoffrey Garen 2020-07-14 13:33:56 PDT
I kinda wish FrameTree offered an iterator, so you could do a range-based for loop over all frames.
Comment 6 EWS 2020-07-14 13:45:54 PDT
Committed r264372: <https://trac.webkit.org/changeset/264372>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 404267 [details].
Comment 7 Alexey Proskuryakov 2020-07-14 22:44:28 PDT
REGRESSION(r3707)

:-)