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

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

Issue 629533002: Fix deadlock that can occur while handling service messages at a breakpoint. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month 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 | « runtime/vm/message.h ('k') | runtime/vm/message_handler.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 Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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_MESSAGE_HANDLER_H_ 5 #ifndef VM_MESSAGE_HANDLER_H_
6 #define VM_MESSAGE_HANDLER_H_ 6 #define VM_MESSAGE_HANDLER_H_
7 7
8 #include "vm/isolate.h" 8 #include "vm/isolate.h"
9 #include "vm/message.h" 9 #include "vm/message.h"
10 #include "vm/thread.h" 10 #include "vm/thread.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 // 47 //
48 // Returns true on success. 48 // Returns true on success.
49 bool HandleNextMessage(); 49 bool HandleNextMessage();
50 50
51 // Handles any OOB messages for this message handler. Can be used 51 // Handles any OOB messages for this message handler. Can be used
52 // even if the message handler is running on the thread pool. 52 // even if the message handler is running on the thread pool.
53 // 53 //
54 // Returns true on success. 54 // Returns true on success.
55 bool HandleOOBMessages(); 55 bool HandleOOBMessages();
56 56
57 // Returns true if there are pending OOB messages for this message
58 // handler.
59 bool HasOOBMessages();
60
57 // A message handler tracks how many live ports it has. 61 // A message handler tracks how many live ports it has.
58 bool HasLivePorts() const { return live_ports_ > 0; } 62 bool HasLivePorts() const { return live_ports_ > 0; }
59 63
60 intptr_t live_ports() const { 64 intptr_t live_ports() const {
61 return live_ports_; 65 return live_ports_;
62 } 66 }
63 67
64 bool paused() const { return paused_ > 0; } 68 bool paused() const { return paused_ > 0; }
65 69
66 void increment_paused() { paused_++; } 70 void increment_paused() { paused_++; }
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 StartCallback start_callback_; 171 StartCallback start_callback_;
168 EndCallback end_callback_; 172 EndCallback end_callback_;
169 CallbackData callback_data_; 173 CallbackData callback_data_;
170 174
171 DISALLOW_COPY_AND_ASSIGN(MessageHandler); 175 DISALLOW_COPY_AND_ASSIGN(MessageHandler);
172 }; 176 };
173 177
174 } // namespace dart 178 } // namespace dart
175 179
176 #endif // VM_MESSAGE_HANDLER_H_ 180 #endif // VM_MESSAGE_HANDLER_H_
OLDNEW
« no previous file with comments | « runtime/vm/message.h ('k') | runtime/vm/message_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698