Index: runtime/vm/scavenger.h |
=================================================================== |
--- runtime/vm/scavenger.h (revision 34735) |
+++ runtime/vm/scavenger.h (working copy) |
@@ -10,6 +10,7 @@ |
#include "vm/flags.h" |
#include "vm/globals.h" |
#include "vm/raw_object.h" |
+#include "vm/spaces.h" |
#include "vm/virtual_memory.h" |
#include "vm/visitor.h" |
@@ -81,6 +82,13 @@ |
intptr_t ExternalInWords() const { |
return external_size_ >> kWordSizeLog2; |
} |
+ SpaceUsage GetCurrentUsage() const { |
+ SpaceUsage usage; |
+ usage.used_in_words = UsedInWords(); |
+ usage.capacity_in_words = CapacityInWords(); |
+ usage.external_in_words = ExternalInWords(); |
+ return usage; |
+ } |
void VisitObjects(ObjectVisitor* visitor) const; |
void VisitObjectPointers(ObjectPointerVisitor* visitor) const; |