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

Side by Side Diff: base/win/wait_chain.h

Issue 1834463002: Identify the hung thread using the Wait Chain Traversal API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: BASE_EXPORT Created 4 years, 8 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 | « base/base.gypi ('k') | base/win/wait_chain.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef BASE_WIN_WAIT_CHAIN_H_
6 #define BASE_WIN_WAIT_CHAIN_H_
7
8 #include <windows.h>
9 #include <wct.h>
10
11 #include <vector>
12
13 #include "base/strings/string16.h"
14
15 namespace base {
16 namespace win {
17
18 using WaitChainNodeVector = std::vector<WAITCHAIN_NODE_INFO>;
19
20 // Gets the wait chain for |thread_id|. Also specifies if the |wait_chain|
21 // contains a deadlock. Returns true on success.
22 //
23 // From MSDN: A wait chain is an alternating sequence of threads and
24 // synchronization objects; each thread waits for the object that follows it,
25 // which is owned by the subsequent thread in the chain.
26 BASE_EXPORT bool GetThreadWaitChain(DWORD thread_id,
27 WaitChainNodeVector* wait_chain,
28 bool* is_deadlock);
29
30 // Returns a string that represents the node for a wait chain.
31 BASE_EXPORT base::string16 WaitChainNodeToString(
32 const WAITCHAIN_NODE_INFO& node);
33
34 } // namespace win
35 } // namespace base
36
37 #endif // BASE_WIN_WAIT_CHAIN_H_
OLDNEW
« no previous file with comments | « base/base.gypi ('k') | base/win/wait_chain.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698