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

Issue 54913003: Scheduler: Switch from high to low latency mode if possible. (Closed)

Created:
7 years, 1 month ago by Dominik Grewe
Modified:
7 years, 1 month ago
Reviewers:
brianderson
CC:
chromium-reviews, cc-bugs_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Scheduler: Switch from high to low latency mode if possible. Detect if the renderer's impl thread is one frame behind the main thread (i.e. the main thread is in a high latency mode). If, based on our estimates, the main thread can produce a new tree before the impl thread's deadline, skip a BeginMainFrame to let the impl thread catch up and operate in low latency mode from then on. This feature is currently disabled by default. BUG=309648 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=233734

Patch Set 1 #

Total comments: 9

Patch Set 2 : Renaming and comments. #

Total comments: 3

Patch Set 3 : Update MainThreadIsInHighLatencyMode() and comments. #

Total comments: 5

Patch Set 4 : Update and add scheduler unit tests. #

Total comments: 1

Patch Set 5 : Add checks for MainThreadIsInHighLatencyMode. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+173 lines, -2 lines) Patch
M cc/scheduler/scheduler.h View 1 2 3 4 2 chunks +5 lines, -0 lines 0 comments Download
M cc/scheduler/scheduler.cc View 1 2 3 2 chunks +18 lines, -0 lines 0 comments Download
M cc/scheduler/scheduler_settings.h View 1 chunk +1 line, -0 lines 0 comments Download
M cc/scheduler/scheduler_settings.cc View 1 1 chunk +2 lines, -1 line 0 comments Download
M cc/scheduler/scheduler_state_machine.h View 1 2 3 chunks +7 lines, -0 lines 0 comments Download
M cc/scheduler/scheduler_state_machine.cc View 1 2 3 5 chunks +51 lines, -1 line 0 comments Download
M cc/scheduler/scheduler_unittest.cc View 1 2 3 4 2 chunks +89 lines, -0 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
Dominik Grewe
PTAL. Feel free to suggest different names :)
7 years, 1 month ago (2013-10-31 16:03:16 UTC) #1
brianderson
Can you add a few scheduler unit tests that: 1) Make sure a main frame ...
7 years, 1 month ago (2013-11-01 00:22:59 UTC) #2
Dominik Grewe
Some updates. Will add unit tests next. https://codereview.chromium.org/54913003/diff/1/cc/scheduler/scheduler.h File cc/scheduler/scheduler.h (right): https://codereview.chromium.org/54913003/diff/1/cc/scheduler/scheduler.h#newcode136 cc/scheduler/scheduler.h:136: bool CanOperateInLowLatencyMode() ...
7 years, 1 month ago (2013-11-01 17:09:13 UTC) #3
brianderson
https://codereview.chromium.org/54913003/diff/1/cc/scheduler/scheduler_state_machine.h File cc/scheduler/scheduler_state_machine.h (right): https://codereview.chromium.org/54913003/diff/1/cc/scheduler/scheduler_state_machine.h#newcode150 cc/scheduler/scheduler_state_machine.h:150: // behind the main thread. We're thus in high ...
7 years, 1 month ago (2013-11-01 21:18:30 UTC) #4
Dominik Grewe
I've updated MainThreadIsInHighLatencyMode so it works no matter what state we're in. PTAL. Tests coming ...
7 years, 1 month ago (2013-11-04 14:10:41 UTC) #5
brianderson
Looking forward to the tests. https://codereview.chromium.org/54913003/diff/180001/cc/scheduler/scheduler.h File cc/scheduler/scheduler.h (right): https://codereview.chromium.org/54913003/diff/180001/cc/scheduler/scheduler.h#newcode136 cc/scheduler/scheduler.h:136: bool CanPaintAndCommitBeforeDeadline() const; Since ...
7 years, 1 month ago (2013-11-05 00:24:17 UTC) #6
Dominik Grewe
I've added some unit tests as requested. Please have a look to see if that's ...
7 years, 1 month ago (2013-11-05 12:24:19 UTC) #7
brianderson
lgtm. Thanks for the tests, they do exactly what I had in mind. As a ...
7 years, 1 month ago (2013-11-06 02:16:54 UTC) #8
brianderson
https://codereview.chromium.org/54913003/diff/290001/cc/scheduler/scheduler_unittest.cc File cc/scheduler/scheduler_unittest.cc (right): https://codereview.chromium.org/54913003/diff/290001/cc/scheduler/scheduler_unittest.cc#newcode1131 cc/scheduler/scheduler_unittest.cc:1131: scheduler->SetNeedsCommit(); Before you land this, can you check the ...
7 years, 1 month ago (2013-11-06 02:38:06 UTC) #9
Dominik Grewe
I've added the checks but I had to add a method Scheduler::MainThreadIsInHighLatencyMode(), otherwise it's a ...
7 years, 1 month ago (2013-11-07 15:21:15 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dominikg@chromium.org/54913003/420001
7 years, 1 month ago (2013-11-07 22:29:03 UTC) #11
commit-bot: I haz the power
7 years, 1 month ago (2013-11-08 00:51:47 UTC) #12
Message was sent while issue was closed.
Change committed as 233734

Powered by Google App Engine
This is Rietveld 408576698