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

Unified Diff: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h

Issue 2640763003: Optimize away updatable_queue_set_ (Closed)
Patch Set: Created 3 years, 11 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: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h
diff --git a/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h b/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h
index 6f85115a9f73d05b35a6f9a4ed51a3847c7d5c24..a681608f82e53de734a590ba84613c9c34ec2473 100644
--- a/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h
+++ b/third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h
@@ -140,9 +140,11 @@ class BLINK_PLATFORM_EXPORT TaskQueueImpl final : public TaskQueue {
const char* GetName() const override;
QueueType GetQueueType() const override;
- // If this returns false then future updates for this queue are not needed
- // unless requested.
- bool MaybeUpdateImmediateWorkQueues();
+ // Returns the current queue of immediate incoming tasks.
Sami 2017/01/18 17:57:04 nit: Something like "Extracts all the tasks from t
alex clarke (OOO till 29th) 2017/01/19 08:50:52 Done.
+ WTF::Deque<TaskQueueImpl::Task> TakeImmediateIncomingQueue();
+
+ // Must only be called from the thread this task queue was created on.
+ void ReloadImmediateWorkQueueIfEmpty();
void AsValueInto(base::trace_event::TracedValue* state) const;
@@ -193,6 +195,7 @@ class BLINK_PLATFORM_EXPORT TaskQueueImpl final : public TaskQueue {
main_thread_only().heap_handle = heap_handle;
}
+ void PushImmediateIncomingTaskForTest(TaskQueueImpl::Task&& task);
EnqueueOrder GetFenceForTest() const;
class QueueEnabledVoterImpl : public QueueEnabledVoter {
@@ -323,9 +326,9 @@ class BLINK_PLATFORM_EXPORT TaskQueueImpl final : public TaskQueue {
}
const QueueType type_;
- const char* name_;
- const char* disabled_by_default_tracing_category_;
- const char* disabled_by_default_verbose_tracing_category_;
+ const char* const name_;
+ const char* const disabled_by_default_tracing_category_;
+ const char* const disabled_by_default_verbose_tracing_category_;
base::ThreadChecker main_thread_checker_;
MainThreadOnly main_thread_only_;

Powered by Google App Engine
This is Rietveld 408576698