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 438 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
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_; } |
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_; | 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(); |
467 void ReleaseOldToNewSlots(); | 467 void ReleaseOldToNewSlots(); |
468 void AllocateOldToOldSlots(); | 468 void AllocateOldToOldSlots(); |
469 void ReleaseOldToOldSlots(); | 469 void ReleaseOldToOldSlots(); |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
649 int progress_bar_; | 649 int progress_bar_; |
650 | 650 |
651 // Count of bytes marked black on page. | 651 // Count of bytes marked black on page. |
652 int live_byte_count_; | 652 int live_byte_count_; |
653 | 653 |
654 // A single slot set for small pages (of size kPageSize) or an array of slot | 654 // A single slot set for small pages (of size kPageSize) or an array of slot |
655 // set for large pages. In the latter case the number of entries in the array | 655 // set for large pages. In the latter case the number of entries in the array |
656 // is ceil(size() / kPageSize). | 656 // is ceil(size() / kPageSize). |
657 SlotSet* old_to_new_slots_; | 657 SlotSet* old_to_new_slots_; |
658 SlotSet* old_to_old_slots_; | 658 SlotSet* old_to_old_slots_; |
659 TypedSlotSet* typed_old_to_new_slots_; | 659 base::AtomicValue<TypedSlotSet*> typed_old_to_new_slots_; |
660 TypedSlotSet* typed_old_to_old_slots_; | 660 TypedSlotSet* typed_old_to_old_slots_; |
661 | 661 |
662 SkipList* skip_list_; | 662 SkipList* skip_list_; |
663 | 663 |
664 intptr_t write_barrier_counter_; | 664 intptr_t write_barrier_counter_; |
665 | 665 |
666 // Assuming the initial allocation on a page is sequential, | 666 // Assuming the initial allocation on a page is sequential, |
667 // count highest number of bytes ever allocated on the page. | 667 // count highest number of bytes ever allocated on the page. |
668 base::AtomicValue<intptr_t> high_water_mark_; | 668 base::AtomicValue<intptr_t> high_water_mark_; |
669 | 669 |
(...skipping 2272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2942 PageIterator old_iterator_; | 2942 PageIterator old_iterator_; |
2943 PageIterator code_iterator_; | 2943 PageIterator code_iterator_; |
2944 PageIterator map_iterator_; | 2944 PageIterator map_iterator_; |
2945 LargePageIterator lo_iterator_; | 2945 LargePageIterator lo_iterator_; |
2946 }; | 2946 }; |
2947 | 2947 |
2948 } // namespace internal | 2948 } // namespace internal |
2949 } // namespace v8 | 2949 } // namespace v8 |
2950 | 2950 |
2951 #endif // V8_HEAP_SPACES_H_ | 2951 #endif // V8_HEAP_SPACES_H_ |
OLD | NEW |