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 #ifndef V8_HEAP_HEAP_H_ | 5 #ifndef V8_HEAP_HEAP_H_ |
6 #define V8_HEAP_HEAP_H_ | 6 #define V8_HEAP_HEAP_H_ |
7 | 7 |
8 #include <cmath> | 8 #include <cmath> |
9 #include <map> | 9 #include <map> |
10 | 10 |
(...skipping 2407 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2418 Space* next(); | 2418 Space* next(); |
2419 | 2419 |
2420 private: | 2420 private: |
2421 Heap* heap_; | 2421 Heap* heap_; |
2422 int counter_; | 2422 int counter_; |
2423 }; | 2423 }; |
2424 | 2424 |
2425 | 2425 |
2426 // Space iterator for iterating over all old spaces of the heap: Old space | 2426 // Space iterator for iterating over all old spaces of the heap: Old space |
2427 // and code space. Returns each space in turn, and null when it is done. | 2427 // and code space. Returns each space in turn, and null when it is done. |
2428 class V8_EXPORT_PRIVATE OldSpaces BASE_EMBEDDED { | 2428 class OldSpaces BASE_EMBEDDED { |
2429 public: | 2429 public: |
2430 explicit OldSpaces(Heap* heap) : heap_(heap), counter_(OLD_SPACE) {} | 2430 explicit OldSpaces(Heap* heap) : heap_(heap), counter_(OLD_SPACE) {} |
2431 OldSpace* next(); | 2431 OldSpace* next(); |
2432 | 2432 |
2433 private: | 2433 private: |
2434 Heap* heap_; | 2434 Heap* heap_; |
2435 int counter_; | 2435 int counter_; |
2436 }; | 2436 }; |
2437 | 2437 |
2438 | 2438 |
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2636 friend class LargeObjectSpace; | 2636 friend class LargeObjectSpace; |
2637 friend class NewSpace; | 2637 friend class NewSpace; |
2638 friend class PagedSpace; | 2638 friend class PagedSpace; |
2639 DISALLOW_COPY_AND_ASSIGN(AllocationObserver); | 2639 DISALLOW_COPY_AND_ASSIGN(AllocationObserver); |
2640 }; | 2640 }; |
2641 | 2641 |
2642 } // namespace internal | 2642 } // namespace internal |
2643 } // namespace v8 | 2643 } // namespace v8 |
2644 | 2644 |
2645 #endif // V8_HEAP_HEAP_H_ | 2645 #endif // V8_HEAP_HEAP_H_ |
OLD | NEW |