Maintainer | ongy |
---|---|
Stability | testing |
Portability | Linux |
Safe Haskell | None |
Language | Haskell2010 |
- data MemoryHandle
- getMemoryAvailable :: MemoryHandle -> IO Int
- getMemoryHandle :: IO MemoryHandle
- getMemoryTotal :: MemoryHandle -> IO Int
- getMemoryUsed :: MemoryHandle -> IO Int
- getMemoryFree :: MemoryHandle -> IO Int
- getMemoryStats :: MemoryHandle -> IO (Int, Int, Int, Int)
Documentation
data MemoryHandle Source #
The memory handle used for all functions
getMemoryAvailable :: MemoryHandle -> IO Int Source #
Return the memory available to userspace
This is accurate (read from kernel) for current kernels. Old kernel (~3.13) estimates this. Old kernels may overestimate.
getMemoryHandle :: IO MemoryHandle Source #
Get a memory handle
getMemoryTotal :: MemoryHandle -> IO Int Source #
Get the total amount of memory in the system
getMemoryUsed :: MemoryHandle -> IO Int Source #
Get the amount of memory used by the kernel and processes
getMemoryFree :: MemoryHandle -> IO Int Source #
Get the amount of memory rported as free by the kernel
getMemoryStats :: MemoryHandle -> IO (Int, Int, Int, Int) Source #
Get memory statistics in one got (with only one read) (total, avail, free, used)