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

Unified Diff: cc/scheduler/scheduler_state_machine.cc

Issue 17587014: cc: Fix infinite BeginFrame that Scheduler causes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Get together all conditions in ProactiveBeginFrameWantedByImplThread() Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/scheduler/scheduler_state_machine.cc
diff --git a/cc/scheduler/scheduler_state_machine.cc b/cc/scheduler/scheduler_state_machine.cc
index 6446e8dcbb7a9b181676c62e84605a85ee1d2630..77cdcd5671b7c124d6ccc02a9510f787d4cb359f 100644
--- a/cc/scheduler/scheduler_state_machine.cc
+++ b/cc/scheduler/scheduler_state_machine.cc
@@ -365,11 +365,11 @@ bool SchedulerStateMachine::BeginFrameNeededToDrawByImplThread() const {
bool SchedulerStateMachine::ProactiveBeginFrameWantedByImplThread() const {
// We should proactively request a BeginFrame if a commit is pending.
- if (needs_commit_ || needs_forced_commit_ ||
- commit_state_ != COMMIT_STATE_IDLE)
- return true;
-
- return false;
+ // However, it is not needed to be proactive inside a BeginFrame
+ // because a commit is performed now.
+ return (needs_commit_ || needs_forced_commit_ ||
+ commit_state_ != COMMIT_STATE_IDLE) &&
+ !inside_begin_frame_;
brianderson 2013/06/24 20:12:31 Can you see if this works instead? I would test it
}
void SchedulerStateMachine::DidEnterBeginFrame(const BeginFrameArgs& args) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698