Rename Chrome threads to use a "Cr" prefix.
Before we carefully used the app (Chrome/Chromium) name, but: 1) these are for internal debugging use only, so why compute this name 2) on Linux the thread ids are limited to 16 characters, and "Chromium" is too long Review URL: http://codereview.chromium.org/2741003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@49296 0039d316-1c4b-4281-b951-d872f2087c98
This commit is contained in:
chrome
browser
gpu
nacl
plugin
profile_import
renderer
service
utility
worker
media/filters
sandbox/src
@ -823,12 +823,9 @@ int BrowserMain(const MainFunctionParams& parameters) {
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager hi_res_timer_manager;
|
||||
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
std::string thread_name_string = WideToASCII(app_name + L"_BrowserMain");
|
||||
|
||||
const char* thread_name = thread_name_string.c_str();
|
||||
PlatformThread::SetName(thread_name);
|
||||
main_message_loop.set_thread_name(thread_name);
|
||||
const char* kThreadName = "CrBrowserMain";
|
||||
PlatformThread::SetName(kThreadName);
|
||||
main_message_loop.set_thread_name(kThreadName);
|
||||
|
||||
// Register the main thread by instantiating it, but don't call any methods.
|
||||
ChromeThread main_thread(ChromeThread::UI, MessageLoop::current());
|
||||
|
@ -35,8 +35,7 @@ int GpuMain(const MainFunctionParams& parameters) {
|
||||
}
|
||||
|
||||
MessageLoop main_message_loop(MessageLoop::TYPE_UI);
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_GpuMain").c_str());
|
||||
PlatformThread::SetName("CrGpuMain");
|
||||
|
||||
#if defined(OS_WIN)
|
||||
win_util::ScopedCOMInitializer com_initializer;
|
||||
|
@ -34,8 +34,7 @@
|
||||
int NaClBrokerMain(const MainFunctionParams& parameters) {
|
||||
// The main thread of the broker.
|
||||
MessageLoopForIO main_message_loop;
|
||||
std::wstring app_name = chrome::kNaClAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_NaClBrokerMain").c_str());
|
||||
PlatformThread::SetName("CrNaClBrokerMain");
|
||||
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager hi_res_timer_manager;
|
||||
@ -122,13 +121,7 @@ int NaClMain(const MainFunctionParams& parameters) {
|
||||
|
||||
// The main thread of the plugin services IO.
|
||||
MessageLoopForIO main_message_loop;
|
||||
// NaCl code runs in a different binary on Win64.
|
||||
#ifdef _WIN64
|
||||
std::wstring app_name = chrome::kNaClAppName;
|
||||
#else
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
#endif
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_NaClMain").c_str());
|
||||
PlatformThread::SetName("CrNaClMain");
|
||||
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager hi_res_timer_manager;
|
||||
|
@ -60,8 +60,7 @@ int PluginMain(const MainFunctionParams& parameters) {
|
||||
InitializeChromeApplication();
|
||||
#endif
|
||||
MessageLoop main_message_loop(MessageLoop::TYPE_UI);
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_PluginMain").c_str());
|
||||
PlatformThread::SetName("CrPluginMain");
|
||||
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager high_resolution_timer_manager;
|
||||
|
@ -16,9 +16,7 @@
|
||||
int ProfileImportMain(const MainFunctionParams& parameters) {
|
||||
// The main message loop of the profile import process.
|
||||
MessageLoop main_message_loop;
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(
|
||||
app_name + L"_ProfileImportMain").c_str());
|
||||
PlatformThread::SetName("CrProfileImportMain");
|
||||
|
||||
ChildProcess profile_import_process;
|
||||
profile_import_process.set_main_thread(new ProfileImportThread());
|
||||
|
@ -236,8 +236,7 @@ int RendererMain(const MainFunctionParams& parameters) {
|
||||
MessageLoop::TYPE_UI : MessageLoop::TYPE_DEFAULT);
|
||||
#endif
|
||||
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_RendererMain").c_str());
|
||||
PlatformThread::SetName("CrRendererMain");
|
||||
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager hi_res_timer_manager;
|
||||
|
@ -15,8 +15,7 @@
|
||||
// Mainline routine for running as the service process.
|
||||
int ServiceProcessMain(const MainFunctionParams& parameters) {
|
||||
MessageLoopForUI main_message_loop;
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_ServiceMain").c_str());
|
||||
PlatformThread::SetName("CrServiceMain");
|
||||
|
||||
ServiceProcess service_process;
|
||||
service_process.Initialize();
|
||||
|
@ -25,8 +25,7 @@
|
||||
int UtilityMain(const MainFunctionParams& parameters) {
|
||||
// The main message loop of the utility process.
|
||||
MessageLoop main_message_loop;
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_UtilityMain").c_str());
|
||||
PlatformThread::SetName("CrUtilityMain");
|
||||
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager hi_res_timer_manager;
|
||||
|
@ -23,8 +23,7 @@
|
||||
int WorkerMain(const MainFunctionParams& parameters) {
|
||||
// The main message loop of the worker process.
|
||||
MessageLoop main_message_loop;
|
||||
std::wstring app_name = chrome::kBrowserAppName;
|
||||
PlatformThread::SetName(WideToASCII(app_name + L"_WorkerMain").c_str());
|
||||
PlatformThread::SetName("CrWorkerMain");
|
||||
|
||||
SystemMonitor system_monitor;
|
||||
HighResolutionTimerManager hi_res_timer_manager;
|
||||
|
@ -213,7 +213,7 @@ bool VideoRendererBase::HasEnded() {
|
||||
|
||||
// PlatformThread::Delegate implementation.
|
||||
void VideoRendererBase::ThreadMain() {
|
||||
PlatformThread::SetName("VideoThread");
|
||||
PlatformThread::SetName("CrVideoRenderer");
|
||||
for (;;) {
|
||||
// State and playback rate to assume for this iteration of the loop.
|
||||
State state;
|
||||
|
@ -138,7 +138,7 @@ DWORD WINAPI BrokerServicesBase::TargetEventsThread(PVOID param) {
|
||||
if (NULL == param)
|
||||
return 1;
|
||||
|
||||
PlatformThread::SetName("BrokerEventThread");
|
||||
PlatformThread::SetName("BrokerEvent");
|
||||
|
||||
BrokerServicesBase* broker = reinterpret_cast<BrokerServicesBase*>(param);
|
||||
HANDLE port = broker->job_port_;
|
||||
|
Reference in New Issue
Block a user