mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-15 00:13:43 +00:00
runtime: add MemStats.Mallocs and Frees
This commit is contained in:
@@ -15,5 +15,7 @@ func ReadMemStats(m *MemStats) {
|
||||
m.HeapSys = m.HeapInuse + m.HeapIdle
|
||||
m.GCSys = 0
|
||||
m.TotalAlloc = gcTotalAlloc
|
||||
m.Mallocs = gcMallocs
|
||||
m.Frees = gcFrees
|
||||
m.Sys = uint64(heapEnd - heapStart)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user