| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 "vm/code_index_table.h" | 9 #include "vm/code_index_table.h" |
| 10 #include "vm/compiler_stats.h" | 10 #include "vm/compiler_stats.h" |
| (...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 387 | 387 |
| 388 RawError* Isolate::StandardRunLoop() { | 388 RawError* Isolate::StandardRunLoop() { |
| 389 ASSERT(message_notify_callback() == NULL); | 389 ASSERT(message_notify_callback() == NULL); |
| 390 ASSERT(message_handler() != NULL); | 390 ASSERT(message_handler() != NULL); |
| 391 | 391 |
| 392 while (message_handler()->HasLivePorts()) { | 392 while (message_handler()->HasLivePorts()) { |
| 393 ASSERT(this == Isolate::Current()); | 393 ASSERT(this == Isolate::Current()); |
| 394 Zone zone(this); | 394 Zone zone(this); |
| 395 HandleScope handle_scope(this); | 395 HandleScope handle_scope(this); |
| 396 | 396 |
| 397 Message* message = message_handler()->Dequeue(0); | 397 Message* message = message_handler()->queue()->Dequeue(0); |
| 398 if (message != NULL) { | 398 if (message != NULL) { |
| 399 if (message->priority() >= Message::kOOBPriority) { | 399 if (message->priority() >= Message::kOOBPriority) { |
| 400 // TODO(turnidge): Out of band messages will not go through the | 400 // TODO(turnidge): Out of band messages will not go through the |
| 401 // regular message handler. Instead they will be dispatched to | 401 // regular message handler. Instead they will be dispatched to |
| 402 // special vm code. Implement. | 402 // special vm code. Implement. |
| 403 UNIMPLEMENTED(); | 403 UNIMPLEMENTED(); |
| 404 } | 404 } |
| 405 const Instance& msg = | 405 const Instance& msg = |
| 406 Instance::Handle(DeserializeMessage(message->data())); | 406 Instance::Handle(DeserializeMessage(message->data())); |
| 407 const Object& result = Object::Handle( | 407 const Object& result = Object::Handle( |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 } | 461 } |
| 462 | 462 |
| 463 | 463 |
| 464 void Isolate::VisitWeakPersistentHandles(HandleVisitor* visitor) { | 464 void Isolate::VisitWeakPersistentHandles(HandleVisitor* visitor) { |
| 465 if (api_state() != NULL) { | 465 if (api_state() != NULL) { |
| 466 api_state()->VisitWeakHandles(visitor); | 466 api_state()->VisitWeakHandles(visitor); |
| 467 } | 467 } |
| 468 } | 468 } |
| 469 | 469 |
| 470 } // namespace dart | 470 } // namespace dart |
| OLD | NEW |