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 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
491 } | 491 } |
492 | 492 |
493 void set_progress_bar(int progress_bar) { | 493 void set_progress_bar(int progress_bar) { |
494 DCHECK(IsFlagSet(HAS_PROGRESS_BAR)); | 494 DCHECK(IsFlagSet(HAS_PROGRESS_BAR)); |
495 progress_bar_ = progress_bar; | 495 progress_bar_ = progress_bar; |
496 } | 496 } |
497 | 497 |
498 void ResetProgressBar() { | 498 void ResetProgressBar() { |
499 if (IsFlagSet(MemoryChunk::HAS_PROGRESS_BAR)) { | 499 if (IsFlagSet(MemoryChunk::HAS_PROGRESS_BAR)) { |
500 set_progress_bar(0); | 500 set_progress_bar(0); |
501 ClearFlag(MemoryChunk::HAS_PROGRESS_BAR); | |
502 } | 501 } |
503 } | 502 } |
504 | 503 |
505 inline Bitmap* markbits() { | 504 inline Bitmap* markbits() { |
506 return Bitmap::FromAddress(address() + kHeaderSize); | 505 return Bitmap::FromAddress(address() + kHeaderSize); |
507 } | 506 } |
508 | 507 |
509 inline uint32_t AddressToMarkbitIndex(Address addr) { | 508 inline uint32_t AddressToMarkbitIndex(Address addr) { |
510 return static_cast<uint32_t>(addr - this->address()) >> kPointerSizeLog2; | 509 return static_cast<uint32_t>(addr - this->address()) >> kPointerSizeLog2; |
511 } | 510 } |
(...skipping 2436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2948 PageIterator old_iterator_; | 2947 PageIterator old_iterator_; |
2949 PageIterator code_iterator_; | 2948 PageIterator code_iterator_; |
2950 PageIterator map_iterator_; | 2949 PageIterator map_iterator_; |
2951 LargePageIterator lo_iterator_; | 2950 LargePageIterator lo_iterator_; |
2952 }; | 2951 }; |
2953 | 2952 |
2954 } // namespace internal | 2953 } // namespace internal |
2955 } // namespace v8 | 2954 } // namespace v8 |
2956 | 2955 |
2957 #endif // V8_HEAP_SPACES_H_ | 2956 #endif // V8_HEAP_SPACES_H_ |
OLD | NEW |