RESOLVED FIXED 188208
Refactoring: Convert HTMLMediaElement::scheduleDelayedAction() to individually schedulable & cancelable tasks
https://bugs.webkit.org/show_bug.cgi?id=188208
Summary Refactoring: Convert HTMLMediaElement::scheduleDelayedAction() to individuall...
Jer Noble
Reported 2018-07-31 16:16:01 PDT
Refactoring: Convert HTMLMediaElement::scheduleDelayedAction() to individually schedulable & cancelable tasks
Attachments
Patch (35.05 KB, patch)
2018-07-31 16:20 PDT, Jer Noble
no flags
Patch (37.19 KB, patch)
2018-08-06 10:56 PDT, Jer Noble
no flags
Archive of layout-test-results from ews103 for mac-sierra (2.29 MB, application/zip)
2018-08-06 12:06 PDT, EWS Watchlist
no flags
Archive of layout-test-results from ews106 for mac-sierra-wk2 (2.88 MB, application/zip)
2018-08-06 12:12 PDT, EWS Watchlist
no flags
Archive of layout-test-results from ews117 for mac-sierra (3.03 MB, application/zip)
2018-08-06 12:53 PDT, EWS Watchlist
no flags
Patch (37.91 KB, patch)
2018-10-16 10:36 PDT, Jer Noble
no flags
Jer Noble
Comment 1 2018-07-31 16:20:06 PDT
Eric Carlson
Comment 2 2018-08-01 09:40:37 PDT
Comment on attachment 346216 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=346216&action=review r=me once the bots are happy > Source/WebCore/html/HTMLMediaElement.cpp:1090 > + ALWAYS_LOG(LOGIDENTIFIER, "task fired"); I think it make more sense to log from the target method, the __func__ preprocessor macro isn't very helpful inside of a lambda. > Source/WebCore/html/HTMLMediaElement.cpp:4394 > + ALWAYS_LOG(LOGIDENTIFIER, "task fired"); Ditto > Source/WebCore/html/HTMLMediaElement.cpp:5248 > + ALWAYS_LOG(LOGIDENTIFIER, "task fired"); Ditto > Source/WebCore/html/HTMLMediaElement.cpp:5557 > + m_loadMediaResourceTask.close(); > + m_configureTextTracksTask.close(); > + m_checkPlaybackTargetCompatablityTask.close(); > + m_updateMediaStateTask.close(); > + m_mediaEngineUpdatedTask.close(); > + m_updatePlayStateTask.close(); > + m_resumeTaskQueue.close(); > + m_seekTaskQueue.close(); > + m_playbackControlsManagerBehaviorRestrictionsQueue.close(); > m_seekTaskQueue.close(); > m_resumeTaskQueue.close(); > - m_shadowDOMTaskQueue.close(); > m_promiseTaskQueue.close(); > m_pauseAfterDetachedTaskQueue.close(); Nit: it looks like this is the same as the code in HTMLMediaElement::stop, might as well put it in a method you can share. > Source/WebCore/html/HTMLMediaElement.cpp:7586 > + ALWAYS_LOG(LOGIDENTIFIER, "task fired"); Ditto the comment about logging in the target method.
Jer Noble
Comment 3 2018-08-01 10:18:05 PDT
(In reply to Eric Carlson from comment #2) > Comment on attachment 346216 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=346216&action=review > > r=me once the bots are happy > > > Source/WebCore/html/HTMLMediaElement.cpp:1090 > > + ALWAYS_LOG(LOGIDENTIFIER, "task fired"); > > I think it make more sense to log from the target method, the __func__ > preprocessor macro isn't very helpful inside of a lambda. While that's true, doing it this way means it's possible to match up the task being scheduled to the task being fired; if we move this inside the called method, we will log whenever that method is called, regardless of whether it was scheduled or not. > > > Source/WebCore/html/HTMLMediaElement.cpp:5557 > > + m_loadMediaResourceTask.close(); > > + m_configureTextTracksTask.close(); > > + m_checkPlaybackTargetCompatablityTask.close(); > > + m_updateMediaStateTask.close(); > > + m_mediaEngineUpdatedTask.close(); > > + m_updatePlayStateTask.close(); > > + m_resumeTaskQueue.close(); > > + m_seekTaskQueue.close(); > > + m_playbackControlsManagerBehaviorRestrictionsQueue.close(); > > m_seekTaskQueue.close(); > > m_resumeTaskQueue.close(); > > - m_shadowDOMTaskQueue.close(); > > m_promiseTaskQueue.close(); > > m_pauseAfterDetachedTaskQueue.close(); > > Nit: it looks like this is the same as the code in HTMLMediaElement::stop, > might as well put it in a method you can share. Will do.
Jer Noble
Comment 4 2018-08-06 10:56:54 PDT
EWS Watchlist
Comment 5 2018-08-06 12:06:18 PDT
Comment on attachment 346634 [details] Patch Attachment 346634 [details] did not pass mac-ews (mac): Output: https://webkit-queues.webkit.org/results/8778145 New failing tests: media/video-controls-no-display-with-text-track.html
EWS Watchlist
Comment 6 2018-08-06 12:06:20 PDT
Created attachment 346639 [details] Archive of layout-test-results from ews103 for mac-sierra The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews103 Port: mac-sierra Platform: Mac OS X 10.12.6
EWS Watchlist
Comment 7 2018-08-06 12:12:45 PDT
Comment on attachment 346634 [details] Patch Attachment 346634 [details] did not pass mac-wk2-ews (mac-wk2): Output: https://webkit-queues.webkit.org/results/8778197 New failing tests: media/track/track-cue-rendering-horizontal.html
EWS Watchlist
Comment 8 2018-08-06 12:12:46 PDT
Created attachment 346640 [details] Archive of layout-test-results from ews106 for mac-sierra-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews106 Port: mac-sierra-wk2 Platform: Mac OS X 10.12.6
EWS Watchlist
Comment 9 2018-08-06 12:53:23 PDT
Comment on attachment 346634 [details] Patch Attachment 346634 [details] did not pass mac-debug-ews (mac): Output: https://webkit-queues.webkit.org/results/8778279 New failing tests: media/video-controls-no-display-with-text-track.html
EWS Watchlist
Comment 10 2018-08-06 12:53:25 PDT
Created attachment 346643 [details] Archive of layout-test-results from ews117 for mac-sierra The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews117 Port: mac-sierra Platform: Mac OS X 10.12.6
Sam Weinig
Comment 11 2018-08-06 13:16:18 PDT
Comment on attachment 346634 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=346634&action=review > Source/WebCore/html/HTMLMediaElement.h:943 > + DeferrableTask<Timer> m_loadMediaResourceTask; It doesn't seem like this one is ever scheduled.
Jer Noble
Comment 12 2018-10-16 10:36:50 PDT
WebKit Commit Bot
Comment 13 2018-10-16 16:13:03 PDT
Comment on attachment 352470 [details] Patch Clearing flags on attachment: 352470 Committed r237207: <https://trac.webkit.org/changeset/237207>
WebKit Commit Bot
Comment 14 2018-10-16 16:13:05 PDT
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 15 2018-10-16 16:14:33 PDT
Note You need to log in before you can comment on or make changes to this bug.