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

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

Issue 1336763002: Last snapshot bits to get working precompiled hello_world on x64. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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
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 "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 871 matching lines...) Expand 10 before | Expand all | Expand 10 after
882 uword stack_allocated_local_address = reinterpret_cast<uword>(&func); 882 uword stack_allocated_local_address = reinterpret_cast<uword>(&func);
883 return stack_allocated_local_address; 883 return stack_allocated_local_address;
884 #endif 884 #endif
885 #else 885 #else
886 uword stack_allocated_local_address = reinterpret_cast<uword>(&func); 886 uword stack_allocated_local_address = reinterpret_cast<uword>(&func);
887 return stack_allocated_local_address; 887 return stack_allocated_local_address;
888 #endif 888 #endif
889 } 889 }
890 890
891 891
892 void Isolate::SetupInstructionsSnapshotPage(
893 const uint8_t* instructions_snapshot_buffer) {
894 InstructionsSnapshot snapshot(instructions_snapshot_buffer);
895 #if defined(DEBUG)
896 OS::Print("Precompiled instructions are at [%" Px ", %" Px ")\n",
siva 2015/09/16 16:45:41 0x%" ..... 0x%" ....
rmacnak 2015/09/16 18:17:18 Done.
897 reinterpret_cast<uword>(snapshot.instructions_start()),
898 reinterpret_cast<uword>(snapshot.instructions_start()) +
899 snapshot.instructions_size());
900 #endif
901 heap_->SetupInstructionsSnapshotPage(snapshot.instructions_start(),
902 snapshot.instructions_size());
903 }
904
905
892 void Isolate::set_debugger_name(const char* name) { 906 void Isolate::set_debugger_name(const char* name) {
893 free(debugger_name_); 907 free(debugger_name_);
894 debugger_name_ = strdup(name); 908 debugger_name_ = strdup(name);
895 } 909 }
896 910
897 911
898 void Isolate::BuildName(const char* name_prefix) { 912 void Isolate::BuildName(const char* name_prefix) {
899 ASSERT(name_ == NULL); 913 ASSERT(name_ == NULL);
900 if (name_prefix == NULL) { 914 if (name_prefix == NULL) {
901 name_prefix = "isolate"; 915 name_prefix = "isolate";
(...skipping 1571 matching lines...) Expand 10 before | Expand all | Expand 10 after
2473 serialized_message_, serialized_message_len_); 2487 serialized_message_, serialized_message_len_);
2474 } 2488 }
2475 2489
2476 2490
2477 void IsolateSpawnState::Cleanup() { 2491 void IsolateSpawnState::Cleanup() {
2478 SwitchIsolateScope switch_scope(I); 2492 SwitchIsolateScope switch_scope(I);
2479 Dart::ShutdownIsolate(); 2493 Dart::ShutdownIsolate();
2480 } 2494 }
2481 2495
2482 } // namespace dart 2496 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698