summaryrefslogtreecommitdiffstats
path: root/base/object_watcher.cc
diff options
context:
space:
mode:
authordarin@google.com <darin@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-07 20:02:27 +0000
committerdarin@google.com <darin@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-07 20:02:27 +0000
commitc17be48b88e3c8614a333a27d79341de7aeeb684 (patch)
tree7a19a0e5f8ae8212f214d205c50dbfcdbd97968e /base/object_watcher.cc
parent345ad0c9f42fc976d58a6adc8b4273735ea74095 (diff)
downloadchromium_src-c17be48b88e3c8614a333a27d79341de7aeeb684.zip
chromium_src-c17be48b88e3c8614a333a27d79341de7aeeb684.tar.gz
chromium_src-c17be48b88e3c8614a333a27d79341de7aeeb684.tar.bz2
This is an experiment to see the impact of a boosted priority on the page
cyclers. I worry that this could lead to starvation of regular tasks (it is common for OnObjectSignaled to do another IO call), so I don't think this is necessarily a good solution. TBR=jar git-svn-id: svn://svn.chromium.org/chrome/trunk/src@530 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/object_watcher.cc')
-rw-r--r--base/object_watcher.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/base/object_watcher.cc b/base/object_watcher.cc
index 9872a4c..e641232 100644
--- a/base/object_watcher.cc
+++ b/base/object_watcher.cc
@@ -141,6 +141,10 @@ void CALLBACK ObjectWatcher::DoneWaiting(void* param, BOOLEAN timed_out) {
// Record that we ran this function.
watch->did_signal = true;
+ // Make this run very soon on the target thread. TODO(darin): This could
+ // lead to starving other tasks on the origin thread.
+ watch->set_priority(1000);
+
// We rely on the locking in PostTask() to ensure that a memory barrier is
// provided, which in turn ensures our change to did_signal can be observed
// on the target thread.