OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/heap/heap.h" | 5 #include "src/heap/heap.h" |
6 | 6 |
7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
8 #include "src/api.h" | 8 #include "src/api.h" |
9 #include "src/ast/scopeinfo.h" | 9 #include "src/ast/scopeinfo.h" |
10 #include "src/base/bits.h" | 10 #include "src/base/bits.h" |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 configured_(false), | 156 configured_(false), |
157 current_gc_flags_(Heap::kNoGCFlags), | 157 current_gc_flags_(Heap::kNoGCFlags), |
158 current_gc_callback_flags_(GCCallbackFlags::kNoGCCallbackFlags), | 158 current_gc_callback_flags_(GCCallbackFlags::kNoGCCallbackFlags), |
159 external_string_table_(this), | 159 external_string_table_(this), |
160 chunks_queued_for_free_(NULL), | 160 chunks_queued_for_free_(NULL), |
161 concurrent_unmapping_tasks_active_(0), | 161 concurrent_unmapping_tasks_active_(0), |
162 pending_unmapping_tasks_semaphore_(0), | 162 pending_unmapping_tasks_semaphore_(0), |
163 gc_callbacks_depth_(0), | 163 gc_callbacks_depth_(0), |
164 deserialization_complete_(false), | 164 deserialization_complete_(false), |
165 strong_roots_list_(NULL), | 165 strong_roots_list_(NULL), |
166 array_buffer_tracker_(NULL) { | 166 array_buffer_tracker_(NULL), |
| 167 force_oom_(false) { |
167 // Allow build-time customization of the max semispace size. Building | 168 // Allow build-time customization of the max semispace size. Building |
168 // V8 with snapshots and a non-default max semispace size is much | 169 // V8 with snapshots and a non-default max semispace size is much |
169 // easier if you can define it as part of the build environment. | 170 // easier if you can define it as part of the build environment. |
170 #if defined(V8_MAX_SEMISPACE_SIZE) | 171 #if defined(V8_MAX_SEMISPACE_SIZE) |
171 max_semi_space_size_ = reserved_semispace_size_ = V8_MAX_SEMISPACE_SIZE; | 172 max_semi_space_size_ = reserved_semispace_size_ = V8_MAX_SEMISPACE_SIZE; |
172 #endif | 173 #endif |
173 | 174 |
174 // Ensure old_generation_size_ is a multiple of kPageSize. | 175 // Ensure old_generation_size_ is a multiple of kPageSize. |
175 DCHECK((max_old_generation_size_ & (Page::kPageSize - 1)) == 0); | 176 DCHECK((max_old_generation_size_ & (Page::kPageSize - 1)) == 0); |
176 | 177 |
(...skipping 5976 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6153 } | 6154 } |
6154 | 6155 |
6155 | 6156 |
6156 // static | 6157 // static |
6157 int Heap::GetStaticVisitorIdForMap(Map* map) { | 6158 int Heap::GetStaticVisitorIdForMap(Map* map) { |
6158 return StaticVisitorBase::GetVisitorId(map); | 6159 return StaticVisitorBase::GetVisitorId(map); |
6159 } | 6160 } |
6160 | 6161 |
6161 } // namespace internal | 6162 } // namespace internal |
6162 } // namespace v8 | 6163 } // namespace v8 |
OLD | NEW |