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

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

Issue 3001463002: [gardening] Revert "Eliminate dependencies on assemblers and code stubs in precompiled runtime." (Closed)
Patch Set: 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 }
205 #else 208 #else
206 return strdup("JIT runtime cannot run a precompiled snapshot"); 209 return strdup("JIT runtime cannot run a precompiled snapshot");
207 #endif 210 #endif
208 } 211 }
209 if (instructions_snapshot == NULL) { 212 if (instructions_snapshot == NULL) {
210 return strdup("Missing instructions snapshot"); 213 return strdup("Missing instructions snapshot");
211 } 214 }
212 } else if (Snapshot::IsFull(vm_snapshot_kind_)) { 215 } else if (Snapshot::IsFull(vm_snapshot_kind_)) {
213 #if defined(DART_PRECOMPILED_RUNTIME) 216 #if defined(DART_PRECOMPILED_RUNTIME)
214 return strdup("Precompiled runtime requires a precompiled snapshot"); 217 return strdup("Precompiled runtime requires a precompiled snapshot");
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after
745 ASSERT(predefined_handles_ != NULL); 748 ASSERT(predefined_handles_ != NULL);
746 return predefined_handles_->handles_.IsValidScopedHandle(address); 749 return predefined_handles_->handles_.IsValidScopedHandle(address);
747 } 750 }
748 751
749 bool Dart::IsReadOnlyApiHandle(Dart_Handle handle) { 752 bool Dart::IsReadOnlyApiHandle(Dart_Handle handle) {
750 ASSERT(predefined_handles_ != NULL); 753 ASSERT(predefined_handles_ != NULL);
751 return predefined_handles_->api_handles_.IsValidHandle(handle); 754 return predefined_handles_->api_handles_.IsValidHandle(handle);
752 } 755 }
753 756
754 } // namespace dart 757 } // 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