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

Side by Side Diff: runtime/vm/thread.cc

Issue 2605933003: Revert "Added isolate + thread high watermark tracking to Observatory" (Closed)
Patch Set: Created 3 years, 11 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/vm/thread.h ('k') | runtime/vm/thread_registry.h » ('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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 #include "vm/thread.h" 5 #include "vm/thread.h"
6 6
7 #include "vm/compiler_stats.h" 7 #include "vm/compiler_stats.h"
8 #include "vm/dart_api_state.h" 8 #include "vm/dart_api_state.h"
9 #include "vm/growable_array.h" 9 #include "vm/growable_array.h"
10 #include "vm/isolate.h" 10 #include "vm/isolate.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 isolate_(NULL), 67 isolate_(NULL),
68 heap_(NULL), 68 heap_(NULL),
69 top_exit_frame_info_(0), 69 top_exit_frame_info_(0),
70 store_buffer_block_(NULL), 70 store_buffer_block_(NULL),
71 vm_tag_(0), 71 vm_tag_(0),
72 task_kind_(kUnknownTask), 72 task_kind_(kUnknownTask),
73 dart_stream_(NULL), 73 dart_stream_(NULL),
74 os_thread_(NULL), 74 os_thread_(NULL),
75 thread_lock_(new Monitor()), 75 thread_lock_(new Monitor()),
76 zone_(NULL), 76 zone_(NULL),
77 current_thread_memory_(0),
78 thread_memory_high_watermark_(0),
79 api_reusable_scope_(NULL), 77 api_reusable_scope_(NULL),
80 api_top_scope_(NULL), 78 api_top_scope_(NULL),
81 top_resource_(NULL), 79 top_resource_(NULL),
82 long_jump_base_(NULL), 80 long_jump_base_(NULL),
83 no_callback_scope_depth_(0), 81 no_callback_scope_depth_(0),
84 #if defined(DEBUG) 82 #if defined(DEBUG)
85 top_handle_scope_(NULL), 83 top_handle_scope_(NULL),
86 no_handle_scope_depth_(0), 84 no_handle_scope_depth_(0),
87 no_safepoint_scope_depth_(0), 85 no_safepoint_scope_depth_(0),
88 #endif 86 #endif
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 206
209 207
210 #ifndef PRODUCT 208 #ifndef PRODUCT
211 // Collect information about each individual zone associated with this thread. 209 // Collect information about each individual zone associated with this thread.
212 void Thread::PrintJSON(JSONStream* stream) const { 210 void Thread::PrintJSON(JSONStream* stream) const {
213 JSONObject jsobj(stream); 211 JSONObject jsobj(stream);
214 jsobj.AddProperty("type", "_Thread"); 212 jsobj.AddProperty("type", "_Thread");
215 jsobj.AddPropertyF("id", "threads/%" Pd "", 213 jsobj.AddPropertyF("id", "threads/%" Pd "",
216 OSThread::ThreadIdToIntPtr(os_thread()->trace_id())); 214 OSThread::ThreadIdToIntPtr(os_thread()->trace_id()));
217 jsobj.AddProperty("kind", TaskKindToCString(task_kind())); 215 jsobj.AddProperty("kind", TaskKindToCString(task_kind()));
218 jsobj.AddProperty("threadMemoryHighWatermark", thread_memory_high_watermark_);
219 Zone* zone = zone_; 216 Zone* zone = zone_;
220 { 217 {
221 JSONArray zone_info_array(&jsobj, "zones"); 218 JSONArray zone_info_array(&jsobj, "zones");
222 zone = zone_; 219 zone = zone_;
223 while (zone != NULL) { 220 while (zone != NULL) {
224 zone_info_array.AddValue(zone); 221 zone_info_array.AddValue(zone);
225 zone = zone->previous(); 222 zone = zone->previous();
226 } 223 }
227 } 224 }
228 } 225 }
(...skipping 589 matching lines...) Expand 10 before | Expand all | Expand 10 after
818 815
819 DisableThreadInterruptsScope::~DisableThreadInterruptsScope() { 816 DisableThreadInterruptsScope::~DisableThreadInterruptsScope() {
820 if (thread() != NULL) { 817 if (thread() != NULL) {
821 OSThread* os_thread = thread()->os_thread(); 818 OSThread* os_thread = thread()->os_thread();
822 ASSERT(os_thread != NULL); 819 ASSERT(os_thread != NULL);
823 os_thread->EnableThreadInterrupts(); 820 os_thread->EnableThreadInterrupts();
824 } 821 }
825 } 822 }
826 823
827 } // namespace dart 824 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/thread.h ('k') | runtime/vm/thread_registry.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698