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 894 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
905 return lo_space(); | 905 return lo_space(); |
906 default: | 906 default: |
907 return paged_space(idx); | 907 return paged_space(idx); |
908 } | 908 } |
909 } | 909 } |
910 | 910 |
911 // Returns name of the space. | 911 // Returns name of the space. |
912 const char* GetSpaceName(int idx); | 912 const char* GetSpaceName(int idx); |
913 | 913 |
914 // =========================================================================== | 914 // =========================================================================== |
915 // API. ====================================================================== | 915 // Embedder heap tracing. ==================================================== |
916 // =========================================================================== | 916 // =========================================================================== |
917 | 917 |
918 void SetEmbedderHeapTracer(EmbedderHeapTracer* tracer); | 918 void SetEmbedderHeapTracer(EmbedderHeapTracer* tracer); |
919 | 919 |
920 EmbedderHeapTracer* embedder_heap_tracer() { return embedder_heap_tracer_; } | |
Hannes Payer (out of office)
2016/04/07 20:38:31
Since the tracer is fully used in mark-compact, it
Marcel Hlopko
2016/04/08 08:08:09
Done.
| |
921 | |
922 bool UsingEmbedderHeapTracer() { return embedder_heap_tracer_; } | |
Hannes Payer (out of office)
2016/04/07 20:38:30
Why don't we just check FLAG_trace_object_groups?
Marcel Hlopko
2016/04/08 08:08:10
I removed the flag (or to be more accurrate, moved
| |
923 | |
924 void TracePossibleWrapper(JSObject* js_object); | |
925 | |
920 void RegisterExternallyReferencedObject(Object** object); | 926 void RegisterExternallyReferencedObject(Object** object); |
921 | 927 |
922 // =========================================================================== | 928 // =========================================================================== |
923 // Getters to other components. ============================================== | 929 // Getters to other components. ============================================== |
924 // =========================================================================== | 930 // =========================================================================== |
925 | 931 |
926 GCTracer* tracer() { return tracer_; } | 932 GCTracer* tracer() { return tracer_; } |
927 | 933 |
928 MemoryAllocator* memory_allocator() { return memory_allocator_; } | 934 MemoryAllocator* memory_allocator() { return memory_allocator_; } |
929 | 935 |
930 EmbedderHeapTracer* embedder_heap_tracer() { return embedder_heap_tracer_; } | |
931 | |
932 PromotionQueue* promotion_queue() { return &promotion_queue_; } | 936 PromotionQueue* promotion_queue() { return &promotion_queue_; } |
933 | 937 |
934 inline Isolate* isolate(); | 938 inline Isolate* isolate(); |
935 | 939 |
936 MarkCompactCollector* mark_compact_collector() { | 940 MarkCompactCollector* mark_compact_collector() { |
937 return mark_compact_collector_; | 941 return mark_compact_collector_; |
938 } | 942 } |
939 | 943 |
940 // =========================================================================== | 944 // =========================================================================== |
941 // Root set access. ========================================================== | 945 // Root set access. ========================================================== |
(...skipping 1719 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2661 friend class LargeObjectSpace; | 2665 friend class LargeObjectSpace; |
2662 friend class NewSpace; | 2666 friend class NewSpace; |
2663 friend class PagedSpace; | 2667 friend class PagedSpace; |
2664 DISALLOW_COPY_AND_ASSIGN(AllocationObserver); | 2668 DISALLOW_COPY_AND_ASSIGN(AllocationObserver); |
2665 }; | 2669 }; |
2666 | 2670 |
2667 } // namespace internal | 2671 } // namespace internal |
2668 } // namespace v8 | 2672 } // namespace v8 |
2669 | 2673 |
2670 #endif // V8_HEAP_HEAP_H_ | 2674 #endif // V8_HEAP_HEAP_H_ |
OLD | NEW |