summaryrefslogtreecommitdiffstats
path: root/chrome/browser/gpu
diff options
context:
space:
mode:
authorccameron@chromium.org <ccameron@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-26 23:50:39 +0000
committerccameron@chromium.org <ccameron@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-26 23:50:39 +0000
commit4e548a80543ee6409e726cf37f9204655b16cf2c (patch)
tree977565325cf801f46706b48b43158bc5f500b201 /chrome/browser/gpu
parent64214381d88ffd3a77b08dcc1619d0e47393212f (diff)
downloadchromium_src-4e548a80543ee6409e726cf37f9204655b16cf2c.zip
chromium_src-4e548a80543ee6409e726cf37f9204655b16cf2c.tar.gz
chromium_src-4e548a80543ee6409e726cf37f9204655b16cf2c.tar.bz2
Disable FCM on Mac OS 10.7 when kSkipGpuDataLoading is set
This is effectively the same thing that is done above this diff, to disable the trial on Windows XP. The trybots on Mac OS 10.7 use the Apple software renderer. This particular combination is very hang-prone. Browser and content shell tests specify kSkipGpuDataLoading, which effectively disables the GPU blacklist, allowing this configuration to slip through and hang. BUG=230931 Review URL: https://chromiumcodereview.appspot.com/14283010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@196885 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gpu')
-rw-r--r--chrome/browser/gpu/chrome_gpu_util.cc19
1 files changed, 18 insertions, 1 deletions
diff --git a/chrome/browser/gpu/chrome_gpu_util.cc b/chrome/browser/gpu/chrome_gpu_util.cc
index d6a0e90..73cca3e 100644
--- a/chrome/browser/gpu/chrome_gpu_util.cc
+++ b/chrome/browser/gpu/chrome_gpu_util.cc
@@ -5,6 +5,9 @@
#include "chrome/browser/gpu/chrome_gpu_util.h"
#include "base/command_line.h"
+#if defined(OS_MACOSX)
+#include "base/mac/mac_util.h"
+#endif
#include "base/metrics/field_trial.h"
#include "base/metrics/histogram.h"
#include "base/version.h"
@@ -49,6 +52,20 @@ bool ShouldRunCompositingFieldTrial() {
return false;
#endif
+#if defined(OS_MACOSX)
+ // Browser and content shell tests hang on 10.7 when the Apple software
+ // renderer is used. These tests ignore the blacklist (which disables
+ // compositing both on 10.7 and when the Apple software renderer is used)
+ // by specifying the kSkipGpuDataLoading switch, so disable forced
+ // compositing here based on the switch and OS version.
+ // http://crbug.com/230931
+ if (base::mac::IsOSLion() &&
+ CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kSkipGpuDataLoading)) {
+ return false;
+ }
+#endif
+
// Don't activate the field trial if force-compositing-mode has been
// explicitly disabled from the command line.
if (CommandLine::ForCurrentProcess()->HasSwitch(
@@ -96,7 +113,7 @@ void InitializeCompositingFieldTrial() {
// http://crbug.com/140866 for linux
#if defined(OS_WIN)
- // Enable threaded compositing on Windows.
+ // Enable threaded compositing on Windows.
threaded_compositing_probability = kDivisor;
#elif defined(OS_MACOSX)
chrome::VersionInfo::Channel channel = chrome::VersionInfo::GetChannel();