diff options
author | shess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-05 23:15:58 +0000 |
---|---|---|
committer | shess@chromium.org <shess@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-05 23:15:58 +0000 |
commit | 56fedfa29f49ce793d3343525f120eaff5f2b752 (patch) | |
tree | a4b709a6fbc9587338f3fed58f5f885e8138486a /chrome/browser/app_controller_mac.mm | |
parent | 27bc9e8ac1922f88fbe003c9b050add4e27321b0 (diff) | |
download | chromium_src-56fedfa29f49ce793d3343525f120eaff5f2b752.zip chromium_src-56fedfa29f49ce793d3343525f120eaff5f2b752.tar.gz chromium_src-56fedfa29f49ce793d3343525f120eaff5f2b752.tar.bz2 |
[Mac] Use Linux WorkerPool code.
Adapts things to use the Linux WorkerPool code by default, with
--disable-linux-workerpool to switch back to the old version.
The old implementation uses NSOperationQueue, which is implemented in
terms of pthread workqueues. These are implicated by the stack traces
from the recent unit test flakiness. This change attempts to
influence that flakiness.
BUG=20471, 60426
TEST=Tree green.
Review URL: http://codereview.chromium.org/4595001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@65273 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/app_controller_mac.mm')
-rw-r--r-- | chrome/browser/app_controller_mac.mm | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/chrome/browser/app_controller_mac.mm b/chrome/browser/app_controller_mac.mm index aa5af1f..f05548a 100644 --- a/chrome/browser/app_controller_mac.mm +++ b/chrome/browser/app_controller_mac.mm @@ -13,6 +13,7 @@ #include "base/message_loop.h" #include "base/string_number_conversions.h" #include "base/sys_string_conversions.h" +#import "base/worker_pool_mac.h" #include "chrome/app/chrome_dll_resource.h" #include "chrome/browser/browser.h" #include "chrome/browser/browser_init.h" @@ -222,6 +223,15 @@ void RecordLastRunAppBundlePath() { if (parsed_command_line.HasSwitch(switches::kActivateOnLaunch)) { [NSApp activateIgnoringOtherApps:YES]; } + + // Temporary flag to revert to the old WorkerPool implementation. + // This will be removed once we either fix the Mac WorkerPool + // implementation, or completely switch to the shared (with Linux) + // implementation. + // http://crbug.com/44392 + if (parsed_command_line.HasSwitch(switches::kDisableLinuxWorkerPool)) { + worker_pool_mac::SetUseLinuxWorkerPool(false); + } } // (NSApplicationDelegate protocol) This is the Apple-approved place to override |