Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(579)

Issue 1368643002: Add a signal to the scheduler that a navigation is expected (Closed)

Created:
5 years, 3 months ago by alex clarke (OOO till 29th)
Modified:
5 years, 2 months ago
CC:
chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, jam, mkwst+moarreviews-renderer_chromium.org, mlamouri+watch-content_chromium.org, nasko+codewatch_chromium.org, scheduler-bugs_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add a signal to the scheduler that a navigation is expected Under some circumstances, the scheduler temporarily blocks expensive tasks to improve responsiveness to user input. We don't want to delay navigations and the signal this patch adds prevents any scheduler imposed delay. Also we rename the OnPageLoad to OnNavigate for consistency. BUG=497761, 510398 Committed: https://crrev.com/c403394390922bcaab4318a50a6b405439d7ca7d Cr-Commit-Position: refs/heads/master@{#351052}

Patch Set 1 #

Total comments: 12

Patch Set 2 : Requested changes #

Total comments: 4

Patch Set 3 : Tweak #

Patch Set 4 : Rebased #

Patch Set 5 : assert to check for double navigation #

Patch Set 6 : Cant rely on the OnNavigationStarted to get called from chromium, so call it from blink too #

Patch Set 7 : Rebased #

Patch Set 8 : We do need ref counts! There can be multiple concurrent navigations. #

Total comments: 2

Patch Set 9 : Rename for Sami #

Unified diffs Side-by-side diffs Delta from patch set Stats (+213 lines, -61 lines) Patch
M components/scheduler/renderer/renderer_scheduler.h View 1 2 3 4 5 6 7 8 1 chunk +11 lines, -2 lines 0 comments Download
M components/scheduler/renderer/renderer_scheduler_impl.h View 1 2 3 4 5 6 7 8 2 chunks +4 lines, -1 line 0 comments Download
M components/scheduler/renderer/renderer_scheduler_impl.cc View 1 2 3 4 5 6 7 8 4 chunks +23 lines, -2 lines 0 comments Download
M components/scheduler/renderer/renderer_scheduler_impl_unittest.cc View 1 2 3 4 5 6 7 8 6 chunks +126 lines, -50 lines 0 comments Download
M components/scheduler/renderer/renderer_web_scheduler_impl.h View 1 2 3 4 5 6 7 8 1 chunk +3 lines, -0 lines 0 comments Download
M components/scheduler/renderer/renderer_web_scheduler_impl.cc View 1 2 3 4 5 6 7 8 1 chunk +12 lines, -0 lines 0 comments Download
M content/renderer/render_frame_impl.cc View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download
M content/test/fake_renderer_scheduler.h View 1 2 3 4 5 6 7 8 1 chunk +3 lines, -1 line 0 comments Download
M content/test/fake_renderer_scheduler.cc View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/loader/NavigationScheduler.cpp View 1 2 3 4 5 6 7 8 4 chunks +12 lines, -2 lines 0 comments Download
M third_party/WebKit/public/platform/WebScheduler.h View 1 2 3 4 5 6 7 8 1 chunk +10 lines, -0 lines 0 comments Download

Messages

Total messages: 52 (20 generated)
alex clarke (OOO till 29th)
5 years, 3 months ago (2015-09-24 11:35:21 UTC) #2
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/1
5 years, 3 months ago (2015-09-24 11:41:34 UTC) #4
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 3 months ago (2015-09-24 12:50:01 UTC) #6
Sami
https://codereview.chromium.org/1368643002/diff/1/components/scheduler/renderer/renderer_scheduler_impl.cc File components/scheduler/renderer/renderer_scheduler_impl.cc (right): https://codereview.chromium.org/1368643002/diff/1/components/scheduler/renderer/renderer_scheduler_impl.cc#newcode821 components/scheduler/renderer/renderer_scheduler_impl.cc:821: base::AutoLock lock(any_thread_lock_); nit: helper_.CheckOnValidThread(); https://codereview.chromium.org/1368643002/diff/1/components/scheduler/renderer/renderer_scheduler_impl.cc#newcode827 components/scheduler/renderer/renderer_scheduler_impl.cc:827: base::AutoLock lock(any_thread_lock_); Ditto. ...
5 years, 3 months ago (2015-09-24 14:15:05 UTC) #7
alex clarke (OOO till 29th)
https://codereview.chromium.org/1368643002/diff/1/components/scheduler/renderer/renderer_scheduler_impl.cc File components/scheduler/renderer/renderer_scheduler_impl.cc (right): https://codereview.chromium.org/1368643002/diff/1/components/scheduler/renderer/renderer_scheduler_impl.cc#newcode821 components/scheduler/renderer/renderer_scheduler_impl.cc:821: base::AutoLock lock(any_thread_lock_); On 2015/09/24 14:15:04, Sami wrote: > nit: ...
5 years, 3 months ago (2015-09-24 14:53:10 UTC) #8
Sami
Great, components/scheduler lgtm with a nit. https://codereview.chromium.org/1368643002/diff/20001/components/scheduler/renderer/renderer_scheduler_impl.cc File components/scheduler/renderer/renderer_scheduler_impl.cc (right): https://codereview.chromium.org/1368643002/diff/20001/components/scheduler/renderer/renderer_scheduler_impl.cc#newcode823 components/scheduler/renderer/renderer_scheduler_impl.cc:823: base::AutoLock lock(any_thread_lock_); nit: ...
5 years, 3 months ago (2015-09-24 15:16:15 UTC) #9
alex clarke (OOO till 29th)
+jochen@ can you please review the content/* and WebKit changes? https://codereview.chromium.org/1368643002/diff/20001/components/scheduler/renderer/renderer_scheduler_impl.cc File components/scheduler/renderer/renderer_scheduler_impl.cc (right): https://codereview.chromium.org/1368643002/diff/20001/components/scheduler/renderer/renderer_scheduler_impl.cc#newcode823 ...
5 years, 3 months ago (2015-09-24 15:37:15 UTC) #11
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/60001
5 years, 2 months ago (2015-09-25 09:39:18 UTC) #13
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 2 months ago (2015-09-25 10:52:29 UTC) #15
jochen (gone - plz use gerrit)
what if two navigations get scheduled, and one is cancelled?
5 years, 2 months ago (2015-09-25 11:21:52 UTC) #16
alex clarke (OOO till 29th)
On 2015/09/25 11:21:52, jochen wrote: > what if two navigations get scheduled, and one is ...
5 years, 2 months ago (2015-09-25 12:12:12 UTC) #17
jochen (gone - plz use gerrit)
lgtm
5 years, 2 months ago (2015-09-25 12:17:24 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/80001
5 years, 2 months ago (2015-09-25 12:37:44 UTC) #21
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/118186)
5 years, 2 months ago (2015-09-25 13:04:16 UTC) #23
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/100001
5 years, 2 months ago (2015-09-25 13:34:50 UTC) #25
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: mac_chromium_compile_dbg_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_compile_dbg_ng/builds/102429) mac_chromium_gn_rel on ...
5 years, 2 months ago (2015-09-25 13:36:21 UTC) #27
alex clarke (OOO till 29th)
PTAL So that assert showed a bug. If NavigationScheduler::navigateTask fires but the chromium side OnNavigationStarted ...
5 years, 2 months ago (2015-09-25 13:37:34 UTC) #28
alex clarke (OOO till 29th)
PTAL So that assert showed a bug. If NavigationScheduler::navigateTask fires but the chromium side OnNavigationStarted ...
5 years, 2 months ago (2015-09-25 13:37:35 UTC) #29
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/100002 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/100002
5 years, 2 months ago (2015-09-25 13:42:16 UTC) #31
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_asan_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_asan_rel_ng/builds/57695)
5 years, 2 months ago (2015-09-25 14:29:17 UTC) #33
alex clarke (OOO till 29th)
So we do need ref counts! The reason is it's possible for there to be ...
5 years, 2 months ago (2015-09-25 15:49:08 UTC) #34
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/130001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/130001
5 years, 2 months ago (2015-09-25 15:50:03 UTC) #36
Sami
Logic looks alright -- just one bikesheddy comment. https://codereview.chromium.org/1368643002/diff/130001/components/scheduler/renderer/renderer_scheduler.h File components/scheduler/renderer/renderer_scheduler.h (right): https://codereview.chromium.org/1368643002/diff/130001/components/scheduler/renderer/renderer_scheduler.h#newcode120 components/scheduler/renderer/renderer_scheduler.h:120: virtual ...
5 years, 2 months ago (2015-09-25 16:18:38 UTC) #37
alex clarke (OOO till 29th)
https://codereview.chromium.org/1368643002/diff/130001/components/scheduler/renderer/renderer_scheduler.h File components/scheduler/renderer/renderer_scheduler.h (right): https://codereview.chromium.org/1368643002/diff/130001/components/scheduler/renderer/renderer_scheduler.h#newcode120 components/scheduler/renderer/renderer_scheduler.h:120: virtual void NavigationTaskPendingIncRef() = 0; On 2015/09/25 16:18:38, Sami ...
5 years, 2 months ago (2015-09-25 16:57:38 UTC) #40
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/150001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/150001
5 years, 2 months ago (2015-09-25 16:58:21 UTC) #41
Sami
Thanks, lgtm.
5 years, 2 months ago (2015-09-25 17:09:01 UTC) #42
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/112445)
5 years, 2 months ago (2015-09-25 18:43:40 UTC) #44
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/150001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/150001
5 years, 2 months ago (2015-09-25 19:27:52 UTC) #46
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years, 2 months ago (2015-09-25 20:26:24 UTC) #48
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1368643002/150001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1368643002/150001
5 years, 2 months ago (2015-09-28 09:19:20 UTC) #50
commit-bot: I haz the power
Committed patchset #9 (id:150001)
5 years, 2 months ago (2015-09-28 10:27:05 UTC) #51
commit-bot: I haz the power
5 years, 2 months ago (2015-09-28 10:27:43 UTC) #52
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/c403394390922bcaab4318a50a6b405439d7ca7d
Cr-Commit-Position: refs/heads/master@{#351052}

Powered by Google App Engine
This is Rietveld 408576698