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

Unified Diff: runtime/lib/vmservice.cc

Issue 2690323003: Hide kernel isolate from isolate list; do not register it either (Closed)
Patch Set: Show kernel isolate if passing flag Created 3 years, 10 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
« no previous file with comments | « no previous file | runtime/vm/kernel_isolate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/vmservice.cc
diff --git a/runtime/lib/vmservice.cc b/runtime/lib/vmservice.cc
index 9d83c13b9d8e421a7bb7b734f77843d561c7e655..ad4e0fa6a1c1a1b98360d2477f9ea8484b9c8922 100644
--- a/runtime/lib/vmservice.cc
+++ b/runtime/lib/vmservice.cc
@@ -16,10 +16,12 @@
#include "vm/service_event.h"
#include "vm/service_isolate.h"
#include "vm/symbols.h"
+#include "vm/kernel_isolate.h"
namespace dart {
DECLARE_FLAG(bool, trace_service);
+DECLARE_FLAG(bool, show_kernel_isolate);
static uint8_t* malloc_allocator(uint8_t* ptr,
intptr_t old_size,
@@ -57,8 +59,14 @@ class RegisterRunningIsolatesVisitor : public IsolateVisitor {
virtual void VisitIsolate(Isolate* isolate) {
ASSERT(ServiceIsolate::IsServiceIsolate(Isolate::Current()));
- if (IsVMInternalIsolate(isolate)) {
- // We do not register the service (and descendants) or the vm-isolate.
+ bool is_kernel_isolate = false;
+#ifndef DART_PRECOMPILED_RUNTIME
+ is_kernel_isolate =
+ KernelIsolate::IsKernelIsolate(isolate) && !FLAG_show_kernel_isolate;
+#endif
+ if (IsVMInternalIsolate(isolate) || is_kernel_isolate) {
+ // We do not register the service (and descendants), the vm-isolate, or
+ // the kernel isolate.
return;
}
// Setup arguments for call.
« no previous file with comments | « no previous file | runtime/vm/kernel_isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698