Commit 85339947 authored by rtenneti@chromium.org's avatar rtenneti@chromium.org

Increased the unresponsive_threshold from 6 to 12

in Beta channel and XP. We will crash the browser
if UI/IO threads don't respond within 24 secs
(instead of 12 secs) in Beta channel and Windows XP.

BUG=90095
R=jar
TEST=thread_watcher unit tests

Review URL: http://codereview.chromium.org/7744015

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@98697 0039d316-1c4b-4281-b951-d872f2087c98
parent b791d9ce
......@@ -16,7 +16,7 @@
#include "content/common/notification_service.h"
#if defined(OS_WIN)
#include <Objbase.h>
#include "base/win/windows_version.h"
#endif
// static
......@@ -417,6 +417,22 @@ void ThreadWatcherList::ParseCommandLine(
uint32* live_threads_threshold) {
// Determine |unresponsive_threshold| based on switches::kCrashOnHangSeconds.
*unresponsive_threshold = kUnresponsiveCount;
if (chrome::VersionInfo::GetChannel() == chrome::VersionInfo::CHANNEL_BETA) {
// Increase the unresponsive_threshold in Beta channel to reduce the number
// of crashes due to ThreadWatcher.
*unresponsive_threshold *= 2;
} else {
// In Canary and Dev channels, for Windows XP (old systems), double the
// unresponsive_threshold to give OS a chance to schedule UI/IO threads a
// time slice to respond with a pong message (to get around limitations with
// the OS).
#if defined(OS_WIN)
if (base::win::GetVersion() <= base::win::VERSION_XP)
*unresponsive_threshold *= 2;
#endif
}
std::string crash_on_hang_seconds =
command_line.GetSwitchValueASCII(switches::kCrashOnHangSeconds);
if (!crash_on_hang_seconds.empty()) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment