OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 #ifndef VM_OBJECT_STORE_H_ | 5 #ifndef VM_OBJECT_STORE_H_ |
6 #define VM_OBJECT_STORE_H_ | 6 #define VM_OBJECT_STORE_H_ |
7 | 7 |
8 #include "vm/object.h" | 8 #include "vm/object.h" |
9 | 9 |
10 namespace dart { | 10 namespace dart { |
(...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
419 RawArray* library_load_error_table() const { | 419 RawArray* library_load_error_table() const { |
420 return library_load_error_table_; | 420 return library_load_error_table_; |
421 } | 421 } |
422 void set_library_load_error_table(const Array& table) { | 422 void set_library_load_error_table(const Array& table) { |
423 library_load_error_table_ = table.raw(); | 423 library_load_error_table_ = table.raw(); |
424 } | 424 } |
425 static intptr_t library_load_error_table_offset() { | 425 static intptr_t library_load_error_table_offset() { |
426 return OFFSET_OF(ObjectStore, library_load_error_table_); | 426 return OFFSET_OF(ObjectStore, library_load_error_table_); |
427 } | 427 } |
428 | 428 |
| 429 RawArray* compile_time_constants() const { |
| 430 return compile_time_constants_; |
| 431 } |
| 432 void set_compile_time_constants(const Array& value) { |
| 433 compile_time_constants_ = value.raw(); |
| 434 } |
| 435 |
429 // Visit all object pointers. | 436 // Visit all object pointers. |
430 void VisitObjectPointers(ObjectPointerVisitor* visitor); | 437 void VisitObjectPointers(ObjectPointerVisitor* visitor); |
431 | 438 |
432 // Called to initialize objects required by the vm but which invoke | 439 // Called to initialize objects required by the vm but which invoke |
433 // dart code. If an error occurs then false is returned and error | 440 // dart code. If an error occurs then false is returned and error |
434 // information is stored in sticky_error(). | 441 // information is stored in sticky_error(). |
435 bool PreallocateObjects(); | 442 bool PreallocateObjects(); |
436 | 443 |
437 void InitKnownObjects(); | 444 void InitKnownObjects(); |
438 | 445 |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
508 RawError* sticky_error_; | 515 RawError* sticky_error_; |
509 RawContext* empty_context_; | 516 RawContext* empty_context_; |
510 RawInstance* stack_overflow_; | 517 RawInstance* stack_overflow_; |
511 RawInstance* out_of_memory_; | 518 RawInstance* out_of_memory_; |
512 RawUnhandledException* preallocated_unhandled_exception_; | 519 RawUnhandledException* preallocated_unhandled_exception_; |
513 RawStacktrace* preallocated_stack_trace_; | 520 RawStacktrace* preallocated_stack_trace_; |
514 RawFunction* lookup_port_handler_; | 521 RawFunction* lookup_port_handler_; |
515 RawTypedData* empty_uint32_array_; | 522 RawTypedData* empty_uint32_array_; |
516 RawFunction* handle_message_function_; | 523 RawFunction* handle_message_function_; |
517 RawArray* library_load_error_table_; | 524 RawArray* library_load_error_table_; |
| 525 RawArray* compile_time_constants_; |
518 RawObject** to() { | 526 RawObject** to() { |
519 return reinterpret_cast<RawObject**>(&library_load_error_table_); | 527 return reinterpret_cast<RawObject**>(&compile_time_constants_); |
520 } | 528 } |
521 | 529 |
522 friend class SnapshotReader; | 530 friend class SnapshotReader; |
523 friend class VmIsolateSnapshotReader; | 531 friend class VmIsolateSnapshotReader; |
524 | 532 |
525 DISALLOW_COPY_AND_ASSIGN(ObjectStore); | 533 DISALLOW_COPY_AND_ASSIGN(ObjectStore); |
526 }; | 534 }; |
527 | 535 |
528 } // namespace dart | 536 } // namespace dart |
529 | 537 |
530 #endif // VM_OBJECT_STORE_H_ | 538 #endif // VM_OBJECT_STORE_H_ |
OLD | NEW |