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

Side by Side Diff: base/tracked_objects.cc

Issue 9192024: Add a convenience typedef LazyInstance<T>::Leaky to avoid repeating T. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 8 years, 11 months 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 | « base/tracked_objects.h ('k') | base/win/sampling_profiler.cc » ('j') | no next file with comments »
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 "base/tracked_objects.h" 5 #include "base/tracked_objects.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 8
9 #include "base/format_macros.h" 9 #include "base/format_macros.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 // static 189 // static
190 int ThreadData::incarnation_counter_ = 0; 190 int ThreadData::incarnation_counter_ = 0;
191 191
192 // static 192 // static
193 ThreadData* ThreadData::all_thread_data_list_head_ = NULL; 193 ThreadData* ThreadData::all_thread_data_list_head_ = NULL;
194 194
195 // static 195 // static
196 ThreadData* ThreadData::first_retired_worker_ = NULL; 196 ThreadData* ThreadData::first_retired_worker_ = NULL;
197 197
198 // static 198 // static
199 base::LazyInstance<base::Lock, 199 base::LazyInstance<base::Lock>::Leaky
200 base::LeakyLazyInstanceTraits<base::Lock> >
201 ThreadData::list_lock_ = LAZY_INSTANCE_INITIALIZER; 200 ThreadData::list_lock_ = LAZY_INSTANCE_INITIALIZER;
202 201
203 // static 202 // static
204 ThreadData::Status ThreadData::status_ = ThreadData::UNINITIALIZED; 203 ThreadData::Status ThreadData::status_ = ThreadData::UNINITIALIZED;
205 204
206 ThreadData::ThreadData(const std::string& suggested_name) 205 ThreadData::ThreadData(const std::string& suggested_name)
207 : next_(NULL), 206 : next_(NULL),
208 next_retired_worker_(NULL), 207 next_retired_worker_(NULL),
209 worker_thread_number_(0), 208 worker_thread_number_(0),
210 incarnation_count_for_pool_(-1) { 209 incarnation_count_for_pool_(-1) {
(...skipping 615 matching lines...) Expand 10 before | Expand all | Expand 10 after
826 ++it) { 825 ++it) {
827 base::DictionaryValue* parent_child = new base::DictionaryValue; 826 base::DictionaryValue* parent_child = new base::DictionaryValue;
828 it->first->ToValue("parent", parent_child); 827 it->first->ToValue("parent", parent_child);
829 it->second->ToValue("child", parent_child); 828 it->second->ToValue("child", parent_child);
830 descendants->Append(parent_child); 829 descendants->Append(parent_child);
831 } 830 }
832 dictionary->Set("descendants", descendants); 831 dictionary->Set("descendants", descendants);
833 } 832 }
834 833
835 } // namespace tracked_objects 834 } // namespace tracked_objects
OLDNEW
« no previous file with comments | « base/tracked_objects.h ('k') | base/win/sampling_profiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698