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

Unified Diff: components/scheduler/child/task_queue_manager.cc

Issue 1259583006: Reland: Explicitly track the scheduler task enqueueing order in a new field (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moved Task struct Created 5 years, 4 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
Index: components/scheduler/child/task_queue_manager.cc
diff --git a/components/scheduler/child/task_queue_manager.cc b/components/scheduler/child/task_queue_manager.cc
index c557665ab7a4b6a5fac49b02fa6f58a461135f56..f080a96f462629e9354aea5da13e108f53121efc 100644
--- a/components/scheduler/child/task_queue_manager.cc
+++ b/components/scheduler/child/task_queue_manager.cc
@@ -125,11 +125,6 @@ void TaskQueueManager::UpdateWorkQueues(
// as the iterator isn't the element being delated.
if (queue->work_queue().empty())
queue->UpdateWorkQueue(&lazy_now, should_trigger_wakeup, previous_task);
- if (!queue->work_queue().empty()) {
- // Currently we should not be getting tasks with delayed run times in any
- // of the work queues.
- DCHECK(queue->work_queue().front().delayed_run_time.is_null());
- }
}
}
@@ -201,7 +196,8 @@ bool TaskQueueManager::ProcessTaskFromWorkQueue(
base::PendingTask* out_previous_task) {
DCHECK(main_thread_checker_.CalledOnValidThread());
scoped_refptr<DeletionSentinel> protect(deletion_sentinel_);
- base::PendingTask pending_task = queue->TakeTaskFromWorkQueue();
+ // TODO(alexclarke): consider std::move() when allowed.
+ internal::TaskQueueImpl::Task pending_task = queue->TakeTaskFromWorkQueue();
if (queue->GetQuiescenceMonitored())
task_was_run_on_quiescence_monitored_queue_ = true;

Powered by Google App Engine
This is Rietveld 408576698