| 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 "include/dart_native_api.h" | 8 #include "include/dart_native_api.h" |
| 9 #include "platform/assert.h" | 9 #include "platform/assert.h" |
| 10 #include "platform/json.h" | 10 #include "platform/json.h" |
| (...skipping 879 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 890 uword stack_allocated_local_address = reinterpret_cast<uword>(&func); | 890 uword stack_allocated_local_address = reinterpret_cast<uword>(&func); |
| 891 return stack_allocated_local_address; | 891 return stack_allocated_local_address; |
| 892 #endif | 892 #endif |
| 893 } | 893 } |
| 894 | 894 |
| 895 | 895 |
| 896 void Isolate::SetupInstructionsSnapshotPage( | 896 void Isolate::SetupInstructionsSnapshotPage( |
| 897 const uint8_t* instructions_snapshot_buffer) { | 897 const uint8_t* instructions_snapshot_buffer) { |
| 898 InstructionsSnapshot snapshot(instructions_snapshot_buffer); | 898 InstructionsSnapshot snapshot(instructions_snapshot_buffer); |
| 899 #if defined(DEBUG) | 899 #if defined(DEBUG) |
| 900 OS::Print("Precompiled instructions are at [0x%" Px ", 0x%" Px ")\n", | 900 if (FLAG_trace_isolates) { |
| 901 reinterpret_cast<uword>(snapshot.instructions_start()), | 901 OS::Print("Precompiled instructions are at [0x%" Px ", 0x%" Px ")\n", |
| 902 reinterpret_cast<uword>(snapshot.instructions_start()) + | 902 reinterpret_cast<uword>(snapshot.instructions_start()), |
| 903 snapshot.instructions_size()); | 903 reinterpret_cast<uword>(snapshot.instructions_start()) + |
| 904 snapshot.instructions_size()); |
| 905 } |
| 904 #endif | 906 #endif |
| 905 heap_->SetupInstructionsSnapshotPage(snapshot.instructions_start(), | 907 heap_->SetupInstructionsSnapshotPage(snapshot.instructions_start(), |
| 906 snapshot.instructions_size()); | 908 snapshot.instructions_size()); |
| 907 } | 909 } |
| 908 | 910 |
| 909 | 911 |
| 910 void Isolate::set_debugger_name(const char* name) { | 912 void Isolate::set_debugger_name(const char* name) { |
| 911 free(debugger_name_); | 913 free(debugger_name_); |
| 912 debugger_name_ = strdup(name); | 914 debugger_name_ = strdup(name); |
| 913 } | 915 } |
| (...skipping 1580 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2494 serialized_message_, serialized_message_len_); | 2496 serialized_message_, serialized_message_len_); |
| 2495 } | 2497 } |
| 2496 | 2498 |
| 2497 | 2499 |
| 2498 void IsolateSpawnState::Cleanup() { | 2500 void IsolateSpawnState::Cleanup() { |
| 2499 SwitchIsolateScope switch_scope(I); | 2501 SwitchIsolateScope switch_scope(I); |
| 2500 Dart::ShutdownIsolate(); | 2502 Dart::ShutdownIsolate(); |
| 2501 } | 2503 } |
| 2502 | 2504 |
| 2503 } // namespace dart | 2505 } // namespace dart |
| OLD | NEW |