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

Unified Diff: cc/scheduler/scheduler_state_machine.cc

Issue 1715863002: cc: Update main_thread_missed_last_deadline in aborted draws. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@abortIsSkip2
Patch Set: + active_tree_needs_first_draw_ = true Created 4 years, 10 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 | cc/scheduler/scheduler_unittest.cc » ('j') | 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 b168034c3bb632006ca90dd6c572cb80ca2f67bf..a1314fa495a318f64794145afdf93b98c7e8eee6 100644
--- a/cc/scheduler/scheduler_state_machine.cc
+++ b/cc/scheduler/scheduler_state_machine.cc
@@ -643,6 +643,13 @@ void SchedulerStateMachine::WillActivate() {
}
void SchedulerStateMachine::WillDrawInternal() {
+ // If a new active tree is pending after the one we are about to draw,
+ // the main thread is in a high latency mode.
+ // main_thread_missed_last_deadline_ is here in addition to
+ // OnBeginImplFrameIdle for cases where the scheduler aborts draws outside
+ // of the deadline.
+ main_thread_missed_last_deadline_ = CommitPending() || has_pending_tree_;
+
// We need to reset needs_redraw_ before we draw since the
// draw itself might request another draw.
needs_redraw_ = false;
« no previous file with comments | « no previous file | cc/scheduler/scheduler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698