diff --git a/src/runtime/gc_leaking.go b/src/runtime/gc_leaking.go index 5c9594277..71c4258b6 100644 --- a/src/runtime/gc_leaking.go +++ b/src/runtime/gc_leaking.go @@ -79,6 +79,9 @@ func ReadMemStats(m *MemStats) { m.Mallocs = gcMallocs m.Frees = gcFrees m.Sys = uint64(heapEnd - heapStart) + // no free -- current in use heap is the total allocated + m.HeapAlloc = gcTotalAlloc + m.Alloc = m.HeapAlloc } func GC() {