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

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

Issue 1368793002: Add OSThread::GetCurrentThreadTraceId and use it in the timeline implementation (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 2 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 | « no previous file | runtime/vm/os_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 VM_OS_THREAD_H_ 5 #ifndef VM_OS_THREAD_H_
6 #define VM_OS_THREAD_H_ 6 #define VM_OS_THREAD_H_
7 7
8 #include "platform/globals.h" 8 #include "platform/globals.h"
9 #include "vm/globals.h" 9 #include "vm/globals.h"
10 10
(...skipping 30 matching lines...) Expand all
41 41
42 // NOTE: Destructor currently ignored on Windows (issue 23474). 42 // NOTE: Destructor currently ignored on Windows (issue 23474).
43 static ThreadLocalKey CreateThreadLocal(ThreadDestructor destructor = NULL); 43 static ThreadLocalKey CreateThreadLocal(ThreadDestructor destructor = NULL);
44 static void DeleteThreadLocal(ThreadLocalKey key); 44 static void DeleteThreadLocal(ThreadLocalKey key);
45 static uword GetThreadLocal(ThreadLocalKey key) { 45 static uword GetThreadLocal(ThreadLocalKey key) {
46 return ThreadInlineImpl::GetThreadLocal(key); 46 return ThreadInlineImpl::GetThreadLocal(key);
47 } 47 }
48 static void SetThreadLocal(ThreadLocalKey key, uword value); 48 static void SetThreadLocal(ThreadLocalKey key, uword value);
49 static intptr_t GetMaxStackSize(); 49 static intptr_t GetMaxStackSize();
50 static ThreadId GetCurrentThreadId(); 50 static ThreadId GetCurrentThreadId();
51 static ThreadId GetCurrentThreadTraceId();
51 static intptr_t CurrentCurrentThreadIdAsIntPtr() { 52 static intptr_t CurrentCurrentThreadIdAsIntPtr() {
52 return ThreadIdToIntPtr(GetCurrentThreadId()); 53 return ThreadIdToIntPtr(GetCurrentThreadId());
53 } 54 }
54 static ThreadJoinId GetCurrentThreadJoinId(); 55 static ThreadJoinId GetCurrentThreadJoinId();
55 static void Join(ThreadJoinId id); 56 static void Join(ThreadJoinId id);
56 static intptr_t ThreadIdToIntPtr(ThreadId id); 57 static intptr_t ThreadIdToIntPtr(ThreadId id);
57 static ThreadId ThreadIdFromIntPtr(intptr_t id); 58 static ThreadId ThreadIdFromIntPtr(intptr_t id);
58 static bool Compare(ThreadId a, ThreadId b); 59 static bool Compare(ThreadId a, ThreadId b);
59 static void GetThreadCpuUsage(ThreadId thread_id, int64_t* cpu_usage); 60 static void GetThreadCpuUsage(ThreadId thread_id, int64_t* cpu_usage);
60 }; 61 };
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 MonitorData data_; // OS-specific data. 113 MonitorData data_; // OS-specific data.
113 114
114 DISALLOW_COPY_AND_ASSIGN(Monitor); 115 DISALLOW_COPY_AND_ASSIGN(Monitor);
115 }; 116 };
116 117
117 118
118 } // namespace dart 119 } // namespace dart
119 120
120 121
121 #endif // VM_OS_THREAD_H_ 122 #endif // VM_OS_THREAD_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/os_thread_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698