WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 41332
Implement unloadEventEnd, loadEventStart, and loadEventEnd
https://bugs.webkit.org/show_bug.cgi?id=41332
Summary
Implement unloadEventEnd, loadEventStart, and loadEventEnd
Tony Gentilcore
Reported
2010-06-28 21:59:15 PDT
Implement Web Timing navigationStart, fetchStart, load and unload events
Attachments
Patch
(14.96 KB, patch)
2010-06-28 22:10 PDT
,
Tony Gentilcore
no flags
Details
Formatted Diff
Diff
Patch
(15.68 KB, patch)
2010-06-29 14:12 PDT
,
Tony Gentilcore
no flags
Details
Formatted Diff
Diff
Merge with 41442
(15.38 KB, patch)
2010-07-02 10:38 PDT
,
Tony Gentilcore
no flags
Details
Formatted Diff
Diff
Patch
(13.92 KB, patch)
2010-07-07 17:35 PDT
,
Tony Gentilcore
no flags
Details
Formatted Diff
Diff
Patch for landing
(13.78 KB, patch)
2010-07-08 10:57 PDT
,
Tony Gentilcore
no flags
Details
Formatted Diff
Diff
Patch for landing
(13.79 KB, patch)
2010-07-09 10:35 PDT
,
Tony Gentilcore
no flags
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
Tony Gentilcore
Comment 1
2010-06-28 22:10:39 PDT
Created
attachment 59985
[details]
Patch
Nate Chapin
Comment 2
2010-06-29 08:50:58 PDT
Comment on
attachment 59985
[details]
Patch
> @@ -1496,6 +1498,9 @@ void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType t > > ASSERT(m_frame->view()); > > + m_frameLoadTimeline = FrameLoadTimeline(); > + m_frameLoadTimeline.navigationStart = currentTime(); > + > if (m_pageDismissalEventBeingDispatched) > return; > > @@ -2494,6 +2499,9 @@ void FrameLoader::continueLoadAfterWillSubmitForm() > > unsigned long identifier = 0; > > + ASSERT(!m_frameLoadTimeline.fetchStart); > + m_frameLoadTimeline.fetchStart = currentTime(); > + > if (Page* page = m_frame->page()) { > identifier = page->progress()->createUniqueIdentifier(); > notifier()->assignIdentifierToInitialRequest(identifier, m_provisionalDocumentLoader.get(), m_provisionalDocumentLoader->originalRequest());
I don't know the precise sequence of this part of FrameLoader well enough to know for certain that these are the correct places for navigationStart and fetchStart. abarth might know better.
> +struct FrameLoadTimeline { > + FrameLoadTimeline() > + : navigationStart(0) > + , unloadEventStart(0) > + , unloadEventEnd(0) > + , fetchStart(0) > + , loadEventStart(0) > + , loadEventEnd(0) > + { > + } > + > + double navigationStart; > + double unloadEventStart; > + double unloadEventEnd; > + double fetchStart; > + double loadEventStart; > + double loadEventEnd; > +}; > +
This should be in FrameLoaderTypes.h
Tony Gentilcore
Comment 3
2010-06-29 14:12:24 PDT
Created
attachment 60052
[details]
Patch
Tony Gentilcore
Comment 4
2010-07-02 10:38:57 PDT
Created
attachment 60378
[details]
Merge with 41442
Tony Gentilcore
Comment 5
2010-07-02 10:41:47 PDT
(In reply to
comment #2
)
> (From update of
attachment 59985
[details]
) > > @@ -1496,6 +1498,9 @@ void FrameLoader::loadWithDocumentLoader(DocumentLoader* loader, FrameLoadType t > > > > ASSERT(m_frame->view()); > > > > + m_frameLoadTimeline = FrameLoadTimeline(); > > + m_frameLoadTimeline.navigationStart = currentTime(); > > + > > if (m_pageDismissalEventBeingDispatched) > > return; > > > > @@ -2494,6 +2499,9 @@ void FrameLoader::continueLoadAfterWillSubmitForm() > > > > unsigned long identifier = 0; > > > > + ASSERT(!m_frameLoadTimeline.fetchStart); > > + m_frameLoadTimeline.fetchStart = currentTime(); > > + > > if (Page* page = m_frame->page()) { > > identifier = page->progress()->createUniqueIdentifier(); > > notifier()->assignIdentifierToInitialRequest(identifier, m_provisionalDocumentLoader.get(), m_provisionalDocumentLoader->originalRequest()); > > I don't know the precise sequence of this part of FrameLoader well enough to know for certain that these are the correct places for navigationStart and fetchStart. abarth might know better.
Adam, are you a good person to make sure these times are marked in the correct places? Or maybe you know someone else who should take a look?
> > > +struct FrameLoadTimeline { > > + FrameLoadTimeline() > > + : navigationStart(0) > > + , unloadEventStart(0) > > + , unloadEventEnd(0) > > + , fetchStart(0) > > + , loadEventStart(0) > > + , loadEventEnd(0) > > + { > > + } > > + > > + double navigationStart; > > + double unloadEventStart; > > + double unloadEventEnd; > > + double fetchStart; > > + double loadEventStart; > > + double loadEventEnd; > > +}; > > + > > This should be in FrameLoaderTypes.h
Tony Gentilcore
Comment 6
2010-07-07 17:27:15 PDT
To make this easier to review, I'm breaking it up into 3 patches. This patch now only implements unloadEventEnd, loadEventStart and loadEventEnd. Those marks are trivial and shouldn't need Adam to look at the trickier parts of FrameLoader.
Tony Gentilcore
Comment 7
2010-07-07 17:35:10 PDT
Created
attachment 60813
[details]
Patch
Nate Chapin
Comment 8
2010-07-08 09:42:54 PDT
Comment on
attachment 60813
[details]
Patch r+ with a nit
> + if (FrameLoader* frameLoader = frame() ? frame()->loader() : 0) > + frameLoader->frameLoadTimeline()->loadEventStart = currentTime(); > dispatchEvent(Event::create(eventNames().loadEvent, false, false), document()); > + if (FrameLoader* frameLoader = frame() ? frame()->loader() : 0) > + frameLoader->frameLoadTimeline()->loadEventEnd = currentTime();
I find these if statements a bit unclear. You don't need to null check the FrameLoader, so maybe just set a Frame* in the if() statement.
Tony Gentilcore
Comment 9
2010-07-08 10:57:16 PDT
Created
attachment 60910
[details]
Patch for landing
WebKit Commit Bot
Comment 10
2010-07-09 07:52:34 PDT
Comment on
attachment 60910
[details]
Patch for landing Rejecting patch 60910 from commit-queue. Unexpected failure when processing patch! Please file a bug against webkit-patch. Failed to run "['./WebKitTools/Scripts/webkit-patch', '--status-host=webkit-commit-queue.appspot.com', 'land-attachment', '--force-clean', '--build', '--non-interactive', '--ignore-builders', '--build-style=both', '--quiet', 60910, '--test', '--parent-command=commit-queue', '--no-update']" exit_code: 1 Last 500 characters of output: webkitpy/tool/commands/stepsequence.py", line 64, in _run step(tool, options).run(state) File "/Users/eseidel/Projects/CommitQueue/WebKitTools/Scripts/webkitpy/tool/steps/validatereviewer.py", line 68, in run if self._has_valid_reviewer(changelog_entry): File "/Users/eseidel/Projects/CommitQueue/WebKitTools/Scripts/webkitpy/tool/steps/validatereviewer.py", line 50, in _has_valid_reviewer if changelog_entry.reviewer(): AttributeError: 'NoneType' object has no attribute 'reviewer'
WebKit Commit Bot
Comment 11
2010-07-09 09:17:11 PDT
Comment on
attachment 60910
[details]
Patch for landing Rejecting patch 60910 from commit-queue. Unexpected failure when processing patch! Please file a bug against webkit-patch. Failed to run "['./WebKitTools/Scripts/webkit-patch', '--status-host=webkit-commit-queue.appspot.com', 'land-attachment', '--force-clean', '--build', '--non-interactive', '--ignore-builders', '--build-style=both', '--quiet', 60910, '--test', '--parent-command=commit-queue', '--no-update']" exit_code: 1 Last 500 characters of output: webkitpy/tool/commands/stepsequence.py", line 64, in _run step(tool, options).run(state) File "/Users/eseidel/Projects/CommitQueue/WebKitTools/Scripts/webkitpy/tool/steps/validatereviewer.py", line 68, in run if self._has_valid_reviewer(changelog_entry): File "/Users/eseidel/Projects/CommitQueue/WebKitTools/Scripts/webkitpy/tool/steps/validatereviewer.py", line 50, in _has_valid_reviewer if changelog_entry.reviewer(): AttributeError: 'NoneType' object has no attribute 'reviewer'
Tony Gentilcore
Comment 12
2010-07-09 10:35:23 PDT
Created
attachment 61058
[details]
Patch for landing
Tony Gentilcore
Comment 13
2010-07-09 13:17:57 PDT
Landed
r62984
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug