| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 #ifndef V8_HEAP_SPACES_H_ | 5 #ifndef V8_HEAP_SPACES_H_ |
| 6 #define V8_HEAP_SPACES_H_ | 6 #define V8_HEAP_SPACES_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <unordered_set> | 10 #include <unordered_set> |
| (...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 446 | 446 |
| 447 size_t size() const { return size_; } | 447 size_t size() const { return size_; } |
| 448 void set_size(size_t size) { size_ = size; } | 448 void set_size(size_t size) { size_ = size; } |
| 449 | 449 |
| 450 inline Heap* heap() const { return heap_; } | 450 inline Heap* heap() const { return heap_; } |
| 451 | 451 |
| 452 inline SkipList* skip_list() { return skip_list_; } | 452 inline SkipList* skip_list() { return skip_list_; } |
| 453 | 453 |
| 454 inline void set_skip_list(SkipList* skip_list) { skip_list_ = skip_list; } | 454 inline void set_skip_list(SkipList* skip_list) { skip_list_ = skip_list; } |
| 455 | 455 |
| 456 inline SlotSet* old_to_new_slots() { return old_to_new_slots_; } | 456 inline SlotSet* old_to_new_slots() { return old_to_new_slots_.Value(); } |
| 457 inline SlotSet* old_to_old_slots() { return old_to_old_slots_; } | 457 inline SlotSet* old_to_old_slots() { return old_to_old_slots_; } |
| 458 inline TypedSlotSet* typed_old_to_new_slots() { | 458 inline TypedSlotSet* typed_old_to_new_slots() { |
| 459 return typed_old_to_new_slots_.Value(); | 459 return typed_old_to_new_slots_.Value(); |
| 460 } | 460 } |
| 461 inline TypedSlotSet* typed_old_to_old_slots() { | 461 inline TypedSlotSet* typed_old_to_old_slots() { |
| 462 return typed_old_to_old_slots_; | 462 return typed_old_to_old_slots_; |
| 463 } | 463 } |
| 464 inline LocalArrayBufferTracker* local_tracker() { return local_tracker_; } | 464 inline LocalArrayBufferTracker* local_tracker() { return local_tracker_; } |
| 465 | 465 |
| 466 V8_EXPORT_PRIVATE void AllocateOldToNewSlots(); | 466 V8_EXPORT_PRIVATE void AllocateOldToNewSlots(); |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 646 // Used by the incremental marker to keep track of the scanning progress in | 646 // Used by the incremental marker to keep track of the scanning progress in |
| 647 // large objects that have a progress bar and are scanned in increments. | 647 // large objects that have a progress bar and are scanned in increments. |
| 648 int progress_bar_; | 648 int progress_bar_; |
| 649 | 649 |
| 650 // Count of bytes marked black on page. | 650 // Count of bytes marked black on page. |
| 651 int live_byte_count_; | 651 int live_byte_count_; |
| 652 | 652 |
| 653 // A single slot set for small pages (of size kPageSize) or an array of slot | 653 // A single slot set for small pages (of size kPageSize) or an array of slot |
| 654 // set for large pages. In the latter case the number of entries in the array | 654 // set for large pages. In the latter case the number of entries in the array |
| 655 // is ceil(size() / kPageSize). | 655 // is ceil(size() / kPageSize). |
| 656 SlotSet* old_to_new_slots_; | 656 base::AtomicValue<SlotSet*> old_to_new_slots_; |
| 657 SlotSet* old_to_old_slots_; | 657 SlotSet* old_to_old_slots_; |
| 658 base::AtomicValue<TypedSlotSet*> typed_old_to_new_slots_; | 658 base::AtomicValue<TypedSlotSet*> typed_old_to_new_slots_; |
| 659 TypedSlotSet* typed_old_to_old_slots_; | 659 TypedSlotSet* typed_old_to_old_slots_; |
| 660 | 660 |
| 661 SkipList* skip_list_; | 661 SkipList* skip_list_; |
| 662 | 662 |
| 663 intptr_t write_barrier_counter_; | 663 intptr_t write_barrier_counter_; |
| 664 | 664 |
| 665 // Assuming the initial allocation on a page is sequential, | 665 // Assuming the initial allocation on a page is sequential, |
| 666 // count highest number of bytes ever allocated on the page. | 666 // count highest number of bytes ever allocated on the page. |
| (...skipping 2280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2947 PageIterator old_iterator_; | 2947 PageIterator old_iterator_; |
| 2948 PageIterator code_iterator_; | 2948 PageIterator code_iterator_; |
| 2949 PageIterator map_iterator_; | 2949 PageIterator map_iterator_; |
| 2950 LargePageIterator lo_iterator_; | 2950 LargePageIterator lo_iterator_; |
| 2951 }; | 2951 }; |
| 2952 | 2952 |
| 2953 } // namespace internal | 2953 } // namespace internal |
| 2954 } // namespace v8 | 2954 } // namespace v8 |
| 2955 | 2955 |
| 2956 #endif // V8_HEAP_SPACES_H_ | 2956 #endif // V8_HEAP_SPACES_H_ |
| OLD | NEW |