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

Side by Side Diff: runtime/bin/thread.h

Issue 1800863002: Cleanup in //runtime/bin (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 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
« no previous file with comments | « runtime/bin/stdio_win.cc ('k') | runtime/bin/thread_android.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) 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 BIN_THREAD_H_ 5 #ifndef BIN_THREAD_H_
6 #define BIN_THREAD_H_ 6 #define BIN_THREAD_H_
7 7
8 #include "platform/globals.h" 8 #include "platform/globals.h"
9 9
10 namespace dart { 10 namespace dart {
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 } 50 }
51 static void SetThreadLocal(ThreadLocalKey key, uword value); 51 static void SetThreadLocal(ThreadLocalKey key, uword value);
52 static intptr_t GetMaxStackSize(); 52 static intptr_t GetMaxStackSize();
53 static ThreadId GetCurrentThreadId(); 53 static ThreadId GetCurrentThreadId();
54 static bool Join(ThreadId id); 54 static bool Join(ThreadId id);
55 static intptr_t ThreadIdToIntPtr(ThreadId id); 55 static intptr_t ThreadIdToIntPtr(ThreadId id);
56 static bool Compare(ThreadId a, ThreadId b); 56 static bool Compare(ThreadId a, ThreadId b);
57 static void GetThreadCpuUsage(ThreadId thread_id, int64_t* cpu_usage); 57 static void GetThreadCpuUsage(ThreadId thread_id, int64_t* cpu_usage);
58 58
59 static void InitOnce(); 59 static void InitOnce();
60
61 private:
62 DISALLOW_ALLOCATION();
63 DISALLOW_IMPLICIT_CONSTRUCTORS(Thread);
60 }; 64 };
61 65
62 66
63 class Mutex { 67 class Mutex {
64 public: 68 public:
65 Mutex(); 69 Mutex();
66 ~Mutex(); 70 ~Mutex();
67 71
68 void Lock(); 72 void Lock();
69 bool TryLock(); 73 bool TryLock();
(...skipping 28 matching lines...) Expand all
98 // Notify waiting threads. 102 // Notify waiting threads.
99 void Notify(); 103 void Notify();
100 void NotifyAll(); 104 void NotifyAll();
101 105
102 private: 106 private:
103 MonitorData data_; // OS-specific data. 107 MonitorData data_; // OS-specific data.
104 108
105 DISALLOW_COPY_AND_ASSIGN(Monitor); 109 DISALLOW_COPY_AND_ASSIGN(Monitor);
106 }; 110 };
107 111
108
109 } // namespace bin 112 } // namespace bin
110 } // namespace dart 113 } // namespace dart
111 114
112 115
113 #endif // BIN_THREAD_H_ 116 #endif // BIN_THREAD_H_
OLDNEW
« no previous file with comments | « runtime/bin/stdio_win.cc ('k') | runtime/bin/thread_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698