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

Side by Side Diff: components/scheduler/renderer/renderer_scheduler_impl.cc

Issue 1927883002: DO NOT LAND: Disable rAF prioritization Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/scheduler/renderer/renderer_scheduler_impl.h" 5 #include "components/scheduler/renderer/renderer_scheduler_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/debug/stack_trace.h" 8 #include "base/debug/stack_trace.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 679 matching lines...) Expand 10 before | Expand all | Expand 10 after
690 // What we really want to do is priorize loading tasks, but that doesn't 690 // What we really want to do is priorize loading tasks, but that doesn't
691 // seem to be safe. Instead we do that by proxy by deprioritizing 691 // seem to be safe. Instead we do that by proxy by deprioritizing
692 // compositor tasks. This should be safe since we've already gone to the 692 // compositor tasks. This should be safe since we've already gone to the
693 // pain of fixing ordering issues with them. 693 // pain of fixing ordering issues with them.
694 new_policy.compositor_queue_policy.priority = 694 new_policy.compositor_queue_policy.priority =
695 TaskQueue::BEST_EFFORT_PRIORITY; 695 TaskQueue::BEST_EFFORT_PRIORITY;
696 } 696 }
697 break; 697 break;
698 698
699 case UseCase::SYNCHRONIZED_GESTURE: 699 case UseCase::SYNCHRONIZED_GESTURE:
700 new_policy.compositor_queue_policy.priority = TaskQueue::HIGH_PRIORITY; 700 //new_policy.compositor_queue_policy.priority = TaskQueue::HIGH_PRIORITY;
701 if (touchstart_expected_soon) { 701 if (touchstart_expected_soon) {
702 expensive_task_policy = ExpensiveTaskPolicy::BLOCK; 702 expensive_task_policy = ExpensiveTaskPolicy::BLOCK;
703 } else { 703 } else {
704 expensive_task_policy = ExpensiveTaskPolicy::THROTTLE; 704 expensive_task_policy = ExpensiveTaskPolicy::THROTTLE;
705 } 705 }
706 break; 706 break;
707 707
708 case UseCase::MAIN_THREAD_GESTURE: 708 case UseCase::MAIN_THREAD_GESTURE:
709 // In main thread gestures we don't have perfect knowledge about which 709 // In main thread gestures we don't have perfect knowledge about which
710 // things we should be prioritizing, so we don't attempt to block 710 // things we should be prioritizing, so we don't attempt to block
711 // expensive tasks because we don't know whether they were integral to the 711 // expensive tasks because we don't know whether they were integral to the
712 // page's functionality or not. 712 // page's functionality or not.
713 new_policy.compositor_queue_policy.priority = TaskQueue::HIGH_PRIORITY; 713 //new_policy.compositor_queue_policy.priority = TaskQueue::HIGH_PRIORITY;
714 break; 714 break;
715 715
716 case UseCase::TOUCHSTART: 716 case UseCase::TOUCHSTART:
717 new_policy.compositor_queue_policy.priority = TaskQueue::HIGH_PRIORITY; 717 new_policy.compositor_queue_policy.priority = TaskQueue::HIGH_PRIORITY;
718 new_policy.loading_queue_policy.is_enabled = false; 718 new_policy.loading_queue_policy.is_enabled = false;
719 new_policy.timer_queue_policy.is_enabled = false; 719 new_policy.timer_queue_policy.is_enabled = false;
720 // NOTE this is a nop due to the above. 720 // NOTE this is a nop due to the above.
721 expensive_task_policy = ExpensiveTaskPolicy::BLOCK; 721 expensive_task_policy = ExpensiveTaskPolicy::BLOCK;
722 break; 722 break;
723 723
(...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
1245 } 1245 }
1246 MainThreadOnly().have_reported_blocking_intervention_since_navigation = 1246 MainThreadOnly().have_reported_blocking_intervention_since_navigation =
1247 true; 1247 true;
1248 BroadcastConsoleWarning( 1248 BroadcastConsoleWarning(
1249 "Deferred long-running timer task(s) to improve scrolling smoothness. " 1249 "Deferred long-running timer task(s) to improve scrolling smoothness. "
1250 "See crbug.com/574343."); 1250 "See crbug.com/574343.");
1251 } 1251 }
1252 } 1252 }
1253 1253
1254 } // namespace scheduler 1254 } // namespace scheduler
OLDNEW
« 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