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

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

Issue 2994863002: Reapply "Eliminate dependencies on assemblers and code stubs in precompiled runtime." (Closed)
Patch Set: Exclude references to disassembler in precompiled mode Created 3 years, 4 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
« no previous file with comments | « runtime/vm/constant_propagator.cc ('k') | runtime/vm/debugger.h » ('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/dart.h" 5 #include "vm/dart.h"
6 6
7 #include "vm/become.h" 7 #include "vm/become.h"
8 #include "vm/clustered_snapshot.h" 8 #include "vm/clustered_snapshot.h"
9 #include "vm/code_observers.h" 9 #include "vm/code_observers.h"
10 #include "vm/cpu.h" 10 #include "vm/cpu.h"
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 const Snapshot* snapshot = Snapshot::SetupFromBuffer(vm_isolate_snapshot); 195 const Snapshot* snapshot = Snapshot::SetupFromBuffer(vm_isolate_snapshot);
196 if (snapshot == NULL) { 196 if (snapshot == NULL) {
197 return strdup("Invalid vm isolate snapshot seen"); 197 return strdup("Invalid vm isolate snapshot seen");
198 } 198 }
199 vm_snapshot_kind_ = snapshot->kind(); 199 vm_snapshot_kind_ = snapshot->kind();
200 200
201 if (Snapshot::IncludesCode(vm_snapshot_kind_)) { 201 if (Snapshot::IncludesCode(vm_snapshot_kind_)) {
202 if (vm_snapshot_kind_ == Snapshot::kFullAOT) { 202 if (vm_snapshot_kind_ == Snapshot::kFullAOT) {
203 #if defined(DART_PRECOMPILED_RUNTIME) 203 #if defined(DART_PRECOMPILED_RUNTIME)
204 vm_isolate_->set_compilation_allowed(false); 204 vm_isolate_->set_compilation_allowed(false);
205 if (!FLAG_precompiled_runtime) {
206 return strdup("Flag --precompilation was not specified");
207 }
208 #else 205 #else
209 return strdup("JIT runtime cannot run a precompiled snapshot"); 206 return strdup("JIT runtime cannot run a precompiled snapshot");
210 #endif 207 #endif
211 } 208 }
212 if (instructions_snapshot == NULL) { 209 if (instructions_snapshot == NULL) {
213 return strdup("Missing instructions snapshot"); 210 return strdup("Missing instructions snapshot");
214 } 211 }
215 } else if (Snapshot::IsFull(vm_snapshot_kind_)) { 212 } else if (Snapshot::IsFull(vm_snapshot_kind_)) {
216 #if defined(DART_PRECOMPILED_RUNTIME) 213 #if defined(DART_PRECOMPILED_RUNTIME)
217 return strdup("Precompiled runtime requires a precompiled snapshot"); 214 return strdup("Precompiled runtime requires a precompiled snapshot");
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after
748 ASSERT(predefined_handles_ != NULL); 745 ASSERT(predefined_handles_ != NULL);
749 return predefined_handles_->handles_.IsValidScopedHandle(address); 746 return predefined_handles_->handles_.IsValidScopedHandle(address);
750 } 747 }
751 748
752 bool Dart::IsReadOnlyApiHandle(Dart_Handle handle) { 749 bool Dart::IsReadOnlyApiHandle(Dart_Handle handle) {
753 ASSERT(predefined_handles_ != NULL); 750 ASSERT(predefined_handles_ != NULL);
754 return predefined_handles_->api_handles_.IsValidHandle(handle); 751 return predefined_handles_->api_handles_.IsValidHandle(handle);
755 } 752 }
756 753
757 } // namespace dart 754 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/constant_propagator.cc ('k') | runtime/vm/debugger.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698