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/object_store.h" | 5 #include "vm/object_store.h" |
6 | 6 |
7 #include "vm/exceptions.h" | 7 #include "vm/exceptions.h" |
8 #include "vm/dart_entry.h" | 8 #include "vm/dart_entry.h" |
9 #include "vm/isolate.h" | 9 #include "vm/isolate.h" |
10 #include "vm/object.h" | 10 #include "vm/object.h" |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 core_library_(Library::null()), | 58 core_library_(Library::null()), |
59 isolate_library_(Library::null()), | 59 isolate_library_(Library::null()), |
60 math_library_(Library::null()), | 60 math_library_(Library::null()), |
61 mirrors_library_(Library::null()), | 61 mirrors_library_(Library::null()), |
62 native_wrappers_library_(Library::null()), | 62 native_wrappers_library_(Library::null()), |
63 root_library_(Library::null()), | 63 root_library_(Library::null()), |
64 typed_data_library_(Library::null()), | 64 typed_data_library_(Library::null()), |
65 libraries_(GrowableObjectArray::null()), | 65 libraries_(GrowableObjectArray::null()), |
66 pending_classes_(GrowableObjectArray::null()), | 66 pending_classes_(GrowableObjectArray::null()), |
67 pending_functions_(GrowableObjectArray::null()), | 67 pending_functions_(GrowableObjectArray::null()), |
| 68 pause_capabilities_(GrowableObjectArray::null()), |
68 sticky_error_(Error::null()), | 69 sticky_error_(Error::null()), |
69 unhandled_exception_handler_(String::null()), | 70 unhandled_exception_handler_(String::null()), |
70 empty_context_(Context::null()), | 71 empty_context_(Context::null()), |
71 stack_overflow_(Instance::null()), | 72 stack_overflow_(Instance::null()), |
72 out_of_memory_(Instance::null()), | 73 out_of_memory_(Instance::null()), |
73 preallocated_stack_trace_(Stacktrace::null()), | 74 preallocated_stack_trace_(Stacktrace::null()), |
74 lookup_port_handler_(Function::null()), | 75 lookup_port_handler_(Function::null()), |
75 handle_message_function_(Function::null()), | 76 handle_message_function_(Function::null()), |
76 default_tag_(UserTag::null()) { | 77 default_tag_(UserTag::null()) { |
77 } | 78 } |
(...skipping 24 matching lines...) Expand all Loading... |
102 ASSERT(this->preallocated_stack_trace() != Stacktrace::null()); | 103 ASSERT(this->preallocated_stack_trace() != Stacktrace::null()); |
103 return true; | 104 return true; |
104 } | 105 } |
105 ASSERT(this->stack_overflow() == Instance::null()); | 106 ASSERT(this->stack_overflow() == Instance::null()); |
106 ASSERT(this->out_of_memory() == Instance::null()); | 107 ASSERT(this->out_of_memory() == Instance::null()); |
107 ASSERT(this->preallocated_stack_trace() == Stacktrace::null()); | 108 ASSERT(this->preallocated_stack_trace() == Stacktrace::null()); |
108 | 109 |
109 ASSERT(this->pending_functions() == GrowableObjectArray::null()); | 110 ASSERT(this->pending_functions() == GrowableObjectArray::null()); |
110 this->pending_functions_ = GrowableObjectArray::New(); | 111 this->pending_functions_ = GrowableObjectArray::New(); |
111 | 112 |
| 113 this->pause_capabilities_ = GrowableObjectArray::New(); |
| 114 |
112 Object& result = Object::Handle(); | 115 Object& result = Object::Handle(); |
113 const Library& library = Library::Handle(Library::CoreLibrary()); | 116 const Library& library = Library::Handle(Library::CoreLibrary()); |
114 | 117 |
115 result = DartLibraryCalls::InstanceCreate(library, | 118 result = DartLibraryCalls::InstanceCreate(library, |
116 Symbols::StackOverflowError(), | 119 Symbols::StackOverflowError(), |
117 Symbols::Dot(), | 120 Symbols::Dot(), |
118 Object::empty_array()); | 121 Object::empty_array()); |
119 if (result.IsError()) { | 122 if (result.IsError()) { |
120 return false; | 123 return false; |
121 } | 124 } |
(...skipping 17 matching lines...) Expand all Loading... |
139 Stacktrace::Handle(Stacktrace::New(code_array, pc_offset_array)); | 142 Stacktrace::Handle(Stacktrace::New(code_array, pc_offset_array)); |
140 // Expansion of inlined functions requires additional memory at run time, | 143 // Expansion of inlined functions requires additional memory at run time, |
141 // avoid it. | 144 // avoid it. |
142 stack_trace.set_expand_inlined(false); | 145 stack_trace.set_expand_inlined(false); |
143 set_preallocated_stack_trace(stack_trace); | 146 set_preallocated_stack_trace(stack_trace); |
144 | 147 |
145 return true; | 148 return true; |
146 } | 149 } |
147 | 150 |
148 } // namespace dart | 151 } // namespace dart |
OLD | NEW |