pub enum MemorySemantics {
LinuxMemAvailable,
MacosVmStatistics,
SysinfoBaseline,
}Expand description
Which platform definition produced the headline memory numbers.
Variants§
LinuxMemAvailable
available is /proc/meminfo’s MemAvailable, the kernel’s own
estimate of allocatable memory without swapping. used is
total - MemAvailable, so page cache is not counted as application use.
MacosVmStatistics
available is derived from host_statistics64 free plus inactive plus
purgeable pages. Wired and compressed pages are reported separately
because neither is reclaimable the way Linux page cache is.
SysinfoBaseline
The cross-platform baseline reported by sysinfo, used when native
enrichment is unavailable. Coarser than either native definition.
Implementations§
Source§impl MemorySemantics
impl MemorySemantics
Sourcepub const fn description(self) -> &'static str
pub const fn description(self) -> &'static str
The explanation rendered on the Inspect screen and in docs/metrics.md.
Trait Implementations§
Source§impl Clone for MemorySemantics
impl Clone for MemorySemantics
Source§fn clone(&self) -> MemorySemantics
fn clone(&self) -> MemorySemantics
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for MemorySemantics
Source§impl Debug for MemorySemantics
impl Debug for MemorySemantics
impl Eq for MemorySemantics
Source§impl PartialEq for MemorySemantics
impl PartialEq for MemorySemantics
impl StructuralPartialEq for MemorySemantics
Auto Trait Implementations§
impl Freeze for MemorySemantics
impl RefUnwindSafe for MemorySemantics
impl Send for MemorySemantics
impl Sync for MemorySemantics
impl Unpin for MemorySemantics
impl UnsafeUnpin for MemorySemantics
impl UnwindSafe for MemorySemantics
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more