Chromium Code Reviews| 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/dart.h" | 5 #include "vm/dart.h" |
| 6 | 6 |
| 7 #include "vm/code_observers.h" | 7 #include "vm/code_observers.h" |
| 8 #include "vm/dart_api_state.h" | 8 #include "vm/dart_api_state.h" |
| 9 #include "vm/dart_entry.h" | 9 #include "vm/dart_entry.h" |
| 10 #include "vm/flags.h" | 10 #include "vm/flags.h" |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 191 } | 191 } |
| 192 | 192 |
| 193 Object::VerifyBuiltinVtables(); | 193 Object::VerifyBuiltinVtables(); |
| 194 | 194 |
| 195 StubCode::Init(isolate); | 195 StubCode::Init(isolate); |
| 196 isolate->megamorphic_cache_table()->InitMissHandler(); | 196 isolate->megamorphic_cache_table()->InitMissHandler(); |
| 197 | 197 |
| 198 isolate->heap()->EnableGrowthControl(); | 198 isolate->heap()->EnableGrowthControl(); |
| 199 isolate->set_init_callback_data(data); | 199 isolate->set_init_callback_data(data); |
| 200 Api::SetupAcquiredError(isolate); | 200 Api::SetupAcquiredError(isolate); |
| 201 if (!isolate->object_store()->PreallocateObjects()) { | |
| 202 return isolate->object_store()->sticky_error(); | |
| 203 } | |
|
siva
2013/06/21 00:55:29
Would be ideal to do this in the
if (snapshot_buf
| |
| 201 if (FLAG_print_class_table) { | 204 if (FLAG_print_class_table) { |
| 202 isolate->class_table()->Print(); | 205 isolate->class_table()->Print(); |
| 203 } | 206 } |
| 204 return Error::null(); | 207 return Error::null(); |
| 205 } | 208 } |
| 206 | 209 |
| 207 | 210 |
| 208 void Dart::ShutdownIsolate() { | 211 void Dart::ShutdownIsolate() { |
| 209 Isolate* isolate = Isolate::Current(); | 212 Isolate* isolate = Isolate::Current(); |
| 210 void* callback_data = isolate->init_callback_data(); | 213 void* callback_data = isolate->init_callback_data(); |
| (...skipping 13 matching lines...) Expand all Loading... | |
| 224 return predefined_handles_->handles_.AllocateScopedHandle(); | 227 return predefined_handles_->handles_.AllocateScopedHandle(); |
| 225 } | 228 } |
| 226 | 229 |
| 227 | 230 |
| 228 bool Dart::IsReadOnlyHandle(uword address) { | 231 bool Dart::IsReadOnlyHandle(uword address) { |
| 229 ASSERT(predefined_handles_ != NULL); | 232 ASSERT(predefined_handles_ != NULL); |
| 230 return predefined_handles_->handles_.IsValidScopedHandle(address); | 233 return predefined_handles_->handles_.IsValidScopedHandle(address); |
| 231 } | 234 } |
| 232 | 235 |
| 233 } // namespace dart | 236 } // namespace dart |
| OLD | NEW |