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

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

Issue 200693002: Set VMTag from stubs when transitioning between Dart and Native (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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/isolate.h ('k') | runtime/vm/native_entry.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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/isolate.h" 5 #include "vm/isolate.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "platform/json.h" 9 #include "platform/json.h"
10 #include "lib/mirrors.h" 10 #include "lib/mirrors.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 } 111 }
112 112
113 113
114 bool IsolateMessageHandler::HandleMessage(Message* message) { 114 bool IsolateMessageHandler::HandleMessage(Message* message) {
115 StartIsolateScope start_scope(isolate_); 115 StartIsolateScope start_scope(isolate_);
116 StackZone zone(isolate_); 116 StackZone zone(isolate_);
117 HandleScope handle_scope(isolate_); 117 HandleScope handle_scope(isolate_);
118 // TODO(turnidge): Rework collection total dart execution. This can 118 // TODO(turnidge): Rework collection total dart execution. This can
119 // overcount when other things (gc, compilation) are active. 119 // overcount when other things (gc, compilation) are active.
120 TIMERSCOPE(isolate_, time_dart_execution); 120 TIMERSCOPE(isolate_, time_dart_execution);
121 VMTagScope tagScope(isolate_, VMTag::kScriptTagId);
122 121
123 // If the message is in band we lookup the receive port to dispatch to. If 122 // If the message is in band we lookup the receive port to dispatch to. If
124 // the receive port is closed, we drop the message without deserializing it. 123 // the receive port is closed, we drop the message without deserializing it.
125 Object& receive_port = Object::Handle(); 124 Object& receive_port = Object::Handle();
126 if (!message->IsOOB()) { 125 if (!message->IsOOB()) {
127 receive_port = DartLibraryCalls::LookupReceivePort(message->dest_port()); 126 receive_port = DartLibraryCalls::LookupReceivePort(message->dest_port());
128 if (receive_port.IsError()) { 127 if (receive_port.IsError()) {
129 return ProcessUnhandledException(Object::null_instance(), 128 return ProcessUnhandledException(Object::null_instance(),
130 Error::Cast(receive_port)); 129 Error::Cast(receive_port));
131 } 130 }
(...skipping 956 matching lines...) Expand 10 before | Expand all | Expand 10 after
1088 return func.raw(); 1087 return func.raw();
1089 } 1088 }
1090 1089
1091 1090
1092 void IsolateSpawnState::Cleanup() { 1091 void IsolateSpawnState::Cleanup() {
1093 SwitchIsolateScope switch_scope(isolate()); 1092 SwitchIsolateScope switch_scope(isolate());
1094 Dart::ShutdownIsolate(); 1093 Dart::ShutdownIsolate();
1095 } 1094 }
1096 1095
1097 } // namespace dart 1096 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/isolate.h ('k') | runtime/vm/native_entry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698