Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(275)

Side by Side Diff: src/heap/object-stats.h

Issue 1310953008: [heap] Move ObjectStatsVisitor into the proper component. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_cleanup-heap-object-stats-1
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/heap/mark-compact.cc ('k') | src/heap/object-stats.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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_OBJECT_STATS_H_ 5 #ifndef V8_HEAP_OBJECT_STATS_H_
6 #define V8_HEAP_OBJECT_STATS_H_ 6 #define V8_HEAP_OBJECT_STATS_H_
7 7
8 #include "src/heap/heap.h" 8 #include "src/heap/heap.h"
9 #include "src/objects.h" 9 #include "src/objects.h"
10 10
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 private: 73 private:
74 Heap* heap_; 74 Heap* heap_;
75 75
76 // Object counts and used memory by InstanceType 76 // Object counts and used memory by InstanceType
77 size_t object_counts_[OBJECT_STATS_COUNT]; 77 size_t object_counts_[OBJECT_STATS_COUNT];
78 size_t object_counts_last_time_[OBJECT_STATS_COUNT]; 78 size_t object_counts_last_time_[OBJECT_STATS_COUNT];
79 size_t object_sizes_[OBJECT_STATS_COUNT]; 79 size_t object_sizes_[OBJECT_STATS_COUNT];
80 size_t object_sizes_last_time_[OBJECT_STATS_COUNT]; 80 size_t object_sizes_last_time_[OBJECT_STATS_COUNT];
81 }; 81 };
82 82
83
84 class ObjectStatsVisitor : public StaticMarkingVisitor<ObjectStatsVisitor> {
85 public:
86 static void Initialize(VisitorDispatchTable<Callback>* original);
87
88 static void VisitBase(VisitorId id, Map* map, HeapObject* obj);
89
90 static void CountFixedArray(FixedArrayBase* fixed_array,
91 FixedArraySubInstanceType fast_type,
92 FixedArraySubInstanceType dictionary_type);
93
94 template <VisitorId id>
95 static inline void Visit(Map* map, HeapObject* obj);
96 };
97
83 } // namespace internal 98 } // namespace internal
84 } // namespace v8 99 } // namespace v8
85 100
86 #endif // V8_HEAP_OBJECT_STATS_H_ 101 #endif // V8_HEAP_OBJECT_STATS_H_
OLDNEW
« no previous file with comments | « src/heap/mark-compact.cc ('k') | src/heap/object-stats.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698