OSS changes from ent fix for openbsd memory lookups. (#11088)

This commit is contained in:
Nick Cabatoff
2021-03-11 10:25:15 -05:00
committed by GitHub
parent 23f9f348d2
commit be48d3d68c
3 changed files with 42 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
package hostutil
// VirutalMemoryStat holds commonly used memory measurements. We must have a
// local type here in order to avoid building the gopsutil library on certain
// arch types.
type VirtualMemoryStat struct {
// Total amount of RAM on this system
Total uint64
// RAM available for programs to allocate
//
// This value is computed from the kernel specific values.
Available uint64
// RAM used by programs
//
// This value is computed from the kernel specific values.
Used uint64
// Percentage of RAM used by programs
//
// This value is computed from the kernel specific values.
UsedPercent float64
}