Bug 214312

Summary: Drop cache of subframe count on the Page
Product: WebKit Reporter: Chris Dumez <cdumez>
Component: Page LoadingAssignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, beidson, ews-watchlist, ggaren, japhet, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

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)

:-)