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

Unified Diff: runtime/vm/message_handler.h

Issue 204003002: Support wedging isolates before startup or before exit. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: runtime/vm/message_handler.h
diff --git a/runtime/vm/message_handler.h b/runtime/vm/message_handler.h
index f7707aa2dc6cdaa09cea950cdd81049d22277f09..e3b36486f8454648312bebd41584a4247c4e07a8 100644
--- a/runtime/vm/message_handler.h
+++ b/runtime/vm/message_handler.h
@@ -63,6 +63,35 @@ class MessageHandler {
// A message handler tracks how many live ports it has.
bool HasLivePorts() const { return live_ports_ > control_ports_; }
+ intptr_t live_ports() const {
+ return live_ports_;
+ }
+
+ intptr_t control_ports() const {
+ return control_ports_;
+ }
+
+ bool wedge_on_start() const {
+ return wedge_on_start_;
+ }
+
+ void set_wedge_on_start(bool wedge_on_start) {
+ wedge_on_start_ = wedge_on_start;
+ }
+
+ bool wedge_on_exit() const {
+ return wedge_on_exit_;
+ }
+
+ void set_wedge_on_exit(bool wedge_on_exit) {
+ wedge_on_exit_ = wedge_on_exit;
+ }
+
+ bool wedged_on_exit() const {
+ return wedged_on_exit_;
+ }
+
+
#if defined(DEBUG)
// Check that it is safe to access this message handler.
//
@@ -129,6 +158,9 @@ class MessageHandler {
MessageQueue* oob_queue_;
intptr_t control_ports_; // The number of open control ports usually 0 or 1.
intptr_t live_ports_; // The number of open ports, including control ports.
+ bool wedge_on_start_;
+ bool wedge_on_exit_;
+ bool wedged_on_exit_;
ThreadPool* pool_;
ThreadPool::Task* task_;
StartCallback start_callback_;

Powered by Google App Engine
This is Rietveld 408576698