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

Unified Diff: runtime/vm/gc_marker.h

Issue 253493002: - Account for live size in marker. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 8 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
« no previous file with comments | « no previous file | runtime/vm/gc_marker.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/gc_marker.h
===================================================================
--- runtime/vm/gc_marker.h (revision 35390)
+++ runtime/vm/gc_marker.h (working copy)
@@ -22,7 +22,7 @@
// of the mark-sweep collection. The marking bit used is defined in RawObject.
class GCMarker : public ValueObject {
public:
- explicit GCMarker(Heap* heap) : heap_(heap) { }
+ explicit GCMarker(Heap* heap) : heap_(heap), marked_bytes_(0) { }
~GCMarker() { }
void MarkObjects(Isolate* isolate,
@@ -30,6 +30,8 @@
bool invoke_api_callbacks,
bool collect_code);
+ intptr_t marked_words() { return marked_bytes_ >> kWordSizeLog2; }
+
private:
void Prologue(Isolate* isolate, bool invoke_api_callbacks);
void Epilogue(Isolate* isolate, bool invoke_api_callbacks);
@@ -47,6 +49,7 @@
Heap* heap_;
+ intptr_t marked_bytes_;
DISALLOW_IMPLICIT_CONSTRUCTORS(GCMarker);
};
« no previous file with comments | « no previous file | runtime/vm/gc_marker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698