Index: src/api.cc |
diff --git a/src/api.cc b/src/api.cc |
index 4377f1a6b366d4f8ac3c1401d71a8a4da2c60d5e..2ded3f73cf7d7c9e5fe9f87060203b75a78991bb 100644 |
--- a/src/api.cc |
+++ b/src/api.cc |
@@ -5494,13 +5494,15 @@ bool v8::V8::Dispose() { |
return true; |
} |
- |
-HeapStatistics::HeapStatistics(): total_heap_size_(0), |
- total_heap_size_executable_(0), |
- total_physical_size_(0), |
- used_heap_size_(0), |
- heap_size_limit_(0) { } |
- |
+HeapStatistics::HeapStatistics() |
+ : total_heap_size_(0), |
+ total_heap_size_executable_(0), |
+ total_physical_size_(0), |
+ total_available_size_(0), |
+ used_heap_size_(0), |
+ heap_size_limit_(0), |
+ malloced_memory_(0), |
+ does_zap_garbage_(0) {} |
HeapSpaceStatistics::HeapSpaceStatistics(): space_name_(0), |
space_size_(0), |
@@ -7401,6 +7403,8 @@ void Isolate::GetHeapStatistics(HeapStatistics* heap_statistics) { |
heap_statistics->total_available_size_ = heap->Available(); |
heap_statistics->used_heap_size_ = heap->SizeOfObjects(); |
heap_statistics->heap_size_limit_ = heap->MaxReserved(); |
+ heap_statistics->malloced_memory_ = |
+ isolate->allocator()->GetCurrentMemoryUsage(); |
heap_statistics->does_zap_garbage_ = heap->ShouldZapGarbage(); |
} |