aboutsummaryrefslogtreecommitdiff
path: root/src/pkg/runtime/malloc.h
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2011-01-19 13:41:42 -0500
committerRuss Cox <rsc@golang.org>2011-01-19 13:41:42 -0500
commitbcd910cfe28eb237741e3bf25fc2c454206a1c30 (patch)
tree89b320ff96ebf2138354f9c4f75323a0a3dadecd /src/pkg/runtime/malloc.h
parent61a4e9812e11efe3ea41142fc49e331c333a333e (diff)
downloadgo-bcd910cfe28eb237741e3bf25fc2c454206a1c30.tar.xz
runtime: add per-pause gc stats
R=r, r2 CC=golang-dev https://golang.org/cl/3980042
Diffstat (limited to 'src/pkg/runtime/malloc.h')
-rw-r--r--src/pkg/runtime/malloc.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pkg/runtime/malloc.h b/src/pkg/runtime/malloc.h
index 0cee6c0ddb..7e750b9170 100644
--- a/src/pkg/runtime/malloc.h
+++ b/src/pkg/runtime/malloc.h
@@ -176,6 +176,7 @@ struct MStats
uint64 sys; // bytes obtained from system (should be sum of xxx_sys below)
uint64 nlookup; // number of pointer lookups
uint64 nmalloc; // number of mallocs
+ uint64 nfree; // number of frees
// Statistics about malloc heap.
// protected by mheap.Lock
@@ -199,7 +200,8 @@ struct MStats
// Statistics about garbage collector.
// Protected by stopping the world during GC.
uint64 next_gc; // next GC (in heap_alloc time)
- uint64 pause_ns;
+ uint64 pause_total_ns;
+ uint64 pause_ns[256];
uint32 numgc;
bool enablegc;
bool debuggc;