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

Unified Diff: runtime/vm/scavenger.cc

Issue 10452006: Implement a heap profiler for the Dart managed heap. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: runtime/vm/scavenger.cc
diff --git a/runtime/vm/scavenger.cc b/runtime/vm/scavenger.cc
index 2410da2ff5e846b124a92f539ffa6b88541a5909..a867fad5f22dfbd4f889823e823a9a096e78ea31 100644
--- a/runtime/vm/scavenger.cc
+++ b/runtime/vm/scavenger.cc
@@ -344,6 +344,16 @@ void Scavenger::VisitObjectPointers(ObjectPointerVisitor* visitor) const {
}
+void Scavenger::VisitObjects(ObjectVisitor* visitor) const {
+ uword cur = FirstObjectStart();
+ while (cur < top_) {
+ RawObject* raw_obj = RawObject::FromAddr(cur);
+ visitor->VisitObject(raw_obj);
+ cur += raw_obj->Size();
+ }
+}
+
+
void Scavenger::Scavenge() {
// TODO(cshapiro): Add a decision procedure for determining when the
// the API callbacks should be invoked.
« runtime/vm/heap_profiler.cc ('K') | « runtime/vm/scavenger.h ('k') | runtime/vm/unicode.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698