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

Unified Diff: android_webview/browser/deferred_gpu_command_service.h

Issue 444173003: aw: Improve idle task scheduling (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove CurrentlyOnUIThread Created 6 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
« no previous file with comments | « no previous file | android_webview/browser/deferred_gpu_command_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/browser/deferred_gpu_command_service.h
diff --git a/android_webview/browser/deferred_gpu_command_service.h b/android_webview/browser/deferred_gpu_command_service.h
index 9a19fdd3d96de96beba5ea487b83c89b4dc846e8..c84df5b6aace45ba737a38973e9469d254c1b20f 100644
--- a/android_webview/browser/deferred_gpu_command_service.h
+++ b/android_webview/browser/deferred_gpu_command_service.h
@@ -45,7 +45,10 @@ class DeferredGpuCommandService
void RunTasks();
// If |is_idle| is false, this will only run older idle tasks.
void PerformIdleWork(bool is_idle);
- bool HasIdleWork();
+ // Flush the idle queue until it is empty. This is different from
+ // PerformIdleWork(is_idle = true), which does not run any newly scheduled
+ // idle tasks during the idle run.
+ void PerformAllIdleWork();
virtual void AddRef() const OVERRIDE;
virtual void Release() const OVERRIDE;
@@ -59,6 +62,7 @@ class DeferredGpuCommandService
static void RequestProcessGL();
DeferredGpuCommandService();
+ size_t IdleQueueSize();
base::Lock tasks_lock_;
std::queue<base::Closure> tasks_;
« no previous file with comments | « no previous file | android_webview/browser/deferred_gpu_command_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698