| OLD | NEW |
| 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 "vm/code_observers.h" | 10 #include "vm/code_observers.h" |
| (...skipping 1473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1484 void Isolate::VisitPrologueWeakPersistentHandles(HandleVisitor* visitor) { | 1484 void Isolate::VisitPrologueWeakPersistentHandles(HandleVisitor* visitor) { |
| 1485 if (api_state() != NULL) { | 1485 if (api_state() != NULL) { |
| 1486 api_state()->VisitPrologueWeakHandles(visitor); | 1486 api_state()->VisitPrologueWeakHandles(visitor); |
| 1487 } | 1487 } |
| 1488 } | 1488 } |
| 1489 | 1489 |
| 1490 | 1490 |
| 1491 void Isolate::PrintJSON(JSONStream* stream, bool ref) { | 1491 void Isolate::PrintJSON(JSONStream* stream, bool ref) { |
| 1492 JSONObject jsobj(stream); | 1492 JSONObject jsobj(stream); |
| 1493 jsobj.AddProperty("type", (ref ? "@Isolate" : "Isolate")); | 1493 jsobj.AddProperty("type", (ref ? "@Isolate" : "Isolate")); |
| 1494 jsobj.AddPropertyF("id", "isolates/%" Pd "", | 1494 jsobj.AddFixedServiceId("isolates/%" Pd "", |
| 1495 static_cast<intptr_t>(main_port())); | 1495 static_cast<intptr_t>(main_port())); |
| 1496 | 1496 |
| 1497 jsobj.AddProperty("name", debugger_name()); | 1497 jsobj.AddProperty("name", debugger_name()); |
| 1498 jsobj.AddPropertyF("number", "%" Pd "", | 1498 jsobj.AddPropertyF("number", "%" Pd "", |
| 1499 static_cast<intptr_t>(main_port())); | 1499 static_cast<intptr_t>(main_port())); |
| 1500 if (ref) { | 1500 if (ref) { |
| 1501 return; | 1501 return; |
| 1502 } | 1502 } |
| 1503 int64_t start_time_millis = start_time() / kMicrosecondsPerMillisecond; | 1503 int64_t start_time_millis = start_time() / kMicrosecondsPerMillisecond; |
| 1504 jsobj.AddProperty64("startTime", start_time_millis); | 1504 jsobj.AddProperty64("startTime", start_time_millis); |
| 1505 IsolateSpawnState* state = spawn_state(); | 1505 IsolateSpawnState* state = spawn_state(); |
| (...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1957 serialized_message_, serialized_message_len_); | 1957 serialized_message_, serialized_message_len_); |
| 1958 } | 1958 } |
| 1959 | 1959 |
| 1960 | 1960 |
| 1961 void IsolateSpawnState::Cleanup() { | 1961 void IsolateSpawnState::Cleanup() { |
| 1962 SwitchIsolateScope switch_scope(I); | 1962 SwitchIsolateScope switch_scope(I); |
| 1963 Dart::ShutdownIsolate(); | 1963 Dart::ShutdownIsolate(); |
| 1964 } | 1964 } |
| 1965 | 1965 |
| 1966 } // namespace dart | 1966 } // namespace dart |
| OLD | NEW |