| Index: base/threading/platform_thread_win.cc
|
| diff --git a/base/threading/platform_thread_win.cc b/base/threading/platform_thread_win.cc
|
| index d5bd9bed08e7978714d989c2a3afcf4a135bed69..8fb34076ed8e4a27fda869a52e71fef23a59a5ba 100644
|
| --- a/base/threading/platform_thread_win.cc
|
| +++ b/base/threading/platform_thread_win.cc
|
| @@ -162,7 +162,7 @@ void PlatformThread::Sleep(TimeDelta duration) {
|
| }
|
|
|
| // static
|
| -void PlatformThread::SetName(const std::string& name) {
|
| +void PlatformThread::SetName(const std::string& name, bool is_worker_thread) {
|
| ThreadIdNameManager::GetInstance()->SetName(CurrentId(), name);
|
|
|
| // On Windows only, we don't need to tell the profiler about the "BrokerEvent"
|
| @@ -171,7 +171,7 @@ void PlatformThread::SetName(const std::string& name) {
|
| // which would also (as a side effect) initialize the profiler in this unused
|
| // context, including setting up thread local storage, etc. The performance
|
| // impact is not terrible, but there is no reason to do initialize it.
|
| - if (name != "BrokerEvent")
|
| + if (name != "BrokerEvent" && !is_worker_thread)
|
| tracked_objects::ThreadData::InitializeThreadContext(name);
|
|
|
| // The debugger needs to be around to catch the name in the exception. If
|
|
|