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

Side by Side Diff: runtime/vm/thread_pool.h

Issue 9700039: Fix wrong initializer order -- not caught on mac build because mac (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 9 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 | « no previous file | no next file » | 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_THREAD_POOL_H_ 5 #ifndef VM_THREAD_POOL_H_
6 #define VM_THREAD_POOL_H_ 6 #define VM_THREAD_POOL_H_
7 7
8 #include "vm/thread.h" 8 #include "vm/thread.h"
9 9
10 namespace dart { 10 namespace dart {
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 bool IsDone() const { return pool_ == NULL; } 70 bool IsDone() const { return pool_ == NULL; }
71 71
72 // Fields owned by Worker. 72 // Fields owned by Worker.
73 Monitor monitor_; 73 Monitor monitor_;
74 ThreadPool* pool_; 74 ThreadPool* pool_;
75 Task* task_; 75 Task* task_;
76 76
77 // Fields owned by ThreadPool. Workers should not look at these 77 // Fields owned by ThreadPool. Workers should not look at these
78 // directly. It's like looking at the sun. 78 // directly. It's like looking at the sun.
79 bool owned_; // Protected by ThreadPool::mutex_ 79 bool owned_; // Protected by ThreadPool::mutex_
80 Worker* all_next_; // Protected by ThreadPool::mutex_
80 Worker* idle_next_; // Protected by ThreadPool::mutex_ 81 Worker* idle_next_; // Protected by ThreadPool::mutex_
81 Worker* all_next_; // Protected by ThreadPool::mutex_
82 82
83 DISALLOW_COPY_AND_ASSIGN(Worker); 83 DISALLOW_COPY_AND_ASSIGN(Worker);
84 }; 84 };
85 85
86 void Shutdown(); 86 void Shutdown();
87 87
88 // Expensive. Use only in assertions. 88 // Expensive. Use only in assertions.
89 bool IsIdle(Worker* worker); 89 bool IsIdle(Worker* worker);
90 90
91 bool RemoveWorkerFromIdleList(Worker* worker); 91 bool RemoveWorkerFromIdleList(Worker* worker);
(...skipping 14 matching lines...) Expand all
106 106
107 static Monitor* exit_monitor_; // Used only in testing. 107 static Monitor* exit_monitor_; // Used only in testing.
108 static int* exit_count_; // Used only in testing. 108 static int* exit_count_; // Used only in testing.
109 109
110 DISALLOW_COPY_AND_ASSIGN(ThreadPool); 110 DISALLOW_COPY_AND_ASSIGN(ThreadPool);
111 }; 111 };
112 112
113 } // namespace dart 113 } // namespace dart
114 114
115 #endif // VM_THREAD_POOL_H_ 115 #endif // VM_THREAD_POOL_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698