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

Side by Side Diff: chrome/browser/metrics/thread_watcher.cc

Issue 8890018: Update Java Bridge to use its own thread in the browser process (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | content/browser/browser_main_loop.h » ('j') | content/browser/browser_main_loop.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/metrics/thread_watcher.h" 5 #include "chrome/browser/metrics/thread_watcher.h"
6 6
7 #include <math.h> // ceil 7 #include <math.h> // ceil
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 } 60 }
61 61
62 void ThreadUnresponsive_PROCESS_LAUNCHER() { 62 void ThreadUnresponsive_PROCESS_LAUNCHER() {
63 CHECK(false); 63 CHECK(false);
64 } 64 }
65 65
66 void ThreadUnresponsive_CACHE() { 66 void ThreadUnresponsive_CACHE() {
67 CHECK(false); 67 CHECK(false);
68 } 68 }
69 69
70 void ThreadUnresponsive_JAVA_BRIDGE() {
71 CHECK(false);
72 }
73
70 void ThreadUnresponsive_IO() { 74 void ThreadUnresponsive_IO() {
71 CHECK(false); 75 CHECK(false);
72 } 76 }
73 77
74 void ThreadUnresponsive_WEB_SOCKET_PROXY() { 78 void ThreadUnresponsive_WEB_SOCKET_PROXY() {
75 CHECK(false); 79 CHECK(false);
76 } 80 }
77 81
78 #if defined(COMPILER_MSVC) 82 #if defined(COMPILER_MSVC)
79 MSVC_POP_WARNING() 83 MSVC_POP_WARNING()
(...skipping 11 matching lines...) Expand all
91 case BrowserThread::WEBKIT: 95 case BrowserThread::WEBKIT:
92 return ThreadUnresponsive_WEBKIT(); 96 return ThreadUnresponsive_WEBKIT();
93 case BrowserThread::FILE: 97 case BrowserThread::FILE:
94 return ThreadUnresponsive_FILE(); 98 return ThreadUnresponsive_FILE();
95 case BrowserThread::FILE_USER_BLOCKING: 99 case BrowserThread::FILE_USER_BLOCKING:
96 return ThreadUnresponsive_FILE_USER_BLOCKING(); 100 return ThreadUnresponsive_FILE_USER_BLOCKING();
97 case BrowserThread::PROCESS_LAUNCHER: 101 case BrowserThread::PROCESS_LAUNCHER:
98 return ThreadUnresponsive_PROCESS_LAUNCHER(); 102 return ThreadUnresponsive_PROCESS_LAUNCHER();
99 case BrowserThread::CACHE: 103 case BrowserThread::CACHE:
100 return ThreadUnresponsive_CACHE(); 104 return ThreadUnresponsive_CACHE();
105 case BrowserThread::JAVA_BRIDGE:
106 return ThreadUnresponsive_JAVA_BRIDGE();
101 case BrowserThread::IO: 107 case BrowserThread::IO:
102 return ThreadUnresponsive_IO(); 108 return ThreadUnresponsive_IO();
103 #if defined(OS_CHROMEOS) 109 #if defined(OS_CHROMEOS)
104 case BrowserThread::WEB_SOCKET_PROXY: 110 case BrowserThread::WEB_SOCKET_PROXY:
105 return ThreadUnresponsive_WEB_SOCKET_PROXY(); 111 return ThreadUnresponsive_WEB_SOCKET_PROXY();
106 #endif 112 #endif
107 case BrowserThread::ID_COUNT: 113 case BrowserThread::ID_COUNT:
108 CHECK(false); // This shouldn't actually be reached! 114 CHECK(false); // This shouldn't actually be reached!
109 break; 115 break;
110 116
(...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after
916 922
917 #if defined(OS_WIN) 923 #if defined(OS_WIN)
918 // On Windows XP, give twice the time for shutdown. 924 // On Windows XP, give twice the time for shutdown.
919 if (base::win::GetVersion() <= base::win::VERSION_XP) 925 if (base::win::GetVersion() <= base::win::VERSION_XP)
920 actual_duration *= 2; 926 actual_duration *= 2;
921 #endif 927 #endif
922 928
923 shutdown_watchdog_ = new ShutdownWatchDogThread(actual_duration); 929 shutdown_watchdog_ = new ShutdownWatchDogThread(actual_duration);
924 shutdown_watchdog_->Arm(); 930 shutdown_watchdog_->Arm();
925 } 931 }
OLDNEW
« no previous file with comments | « no previous file | content/browser/browser_main_loop.h » ('j') | content/browser/browser_main_loop.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698