Skip to main content

Stat

pub struct Stat {
Show 72 fields pub anon: Option<u64>, pub file: Option<u64>, pub kernel: Option<u64>, pub kernel_stack: Option<u64>, pub pagetables: Option<u64>, pub sec_pagetables: Option<u64>, pub percpu: Option<u64>, pub sock: Option<u64>, pub vmalloc: Option<u64>, pub shmem: Option<u64>, pub zswap: Option<u64>, pub zswapped: Option<u64>, pub zswap_incomp: Option<u64>, pub file_mapped: Option<u64>, pub file_dirty: Option<u64>, pub file_writeback: Option<u64>, pub swapcached: Option<u64>, pub anon_thp: Option<u64>, pub file_thp: Option<u64>, pub shmem_thp: Option<u64>, pub inactive_anon: Option<u64>, pub active_anon: Option<u64>, pub inactive_file: Option<u64>, pub active_file: Option<u64>, pub unevictable: Option<u64>, pub slab_reclaimable: Option<u64>, pub slab_unreclaimable: Option<u64>, pub slab: Option<u64>, pub hugetlb: Option<u64>, pub workingset_refault_anon: Option<u64>, pub workingset_refault_file: Option<u64>, pub workingset_activate_anon: Option<u64>, pub workingset_activate_file: Option<u64>, pub workingset_restore_anon: Option<u64>, pub workingset_restore_file: Option<u64>, pub workingset_nodereclaim: Option<u64>, pub pgdemote_kswapd: Option<u64>, pub pgdemote_direct: Option<u64>, pub pgdemote_khugepaged: Option<u64>, pub pgdemote_proactive: Option<u64>, pub pgsteal_kswapd: Option<u64>, pub pgsteal_direct: Option<u64>, pub pgsteal_khugepaged: Option<u64>, pub pgsteal_proactive: Option<u64>, pub pgscan_kswapd: Option<u64>, pub pgscan_direct: Option<u64>, pub pgscan_khugepaged: Option<u64>, pub pgscan_proactive: Option<u64>, pub pgrefill: Option<u64>, pub pgpromote_success: Option<u64>, pub pgscan: Option<u64>, pub pgsteal: Option<u64>, pub pswpin: Option<u64>, pub pswpout: Option<u64>, pub pgfault: Option<u64>, pub pgmajfault: Option<u64>, pub pgactivate: Option<u64>, pub pgdeactivate: Option<u64>, pub pglazyfree: Option<u64>, pub pglazyfreed: Option<u64>, pub swpin_zero: Option<u64>, pub swpout_zero: Option<u64>, pub zswpin: Option<u64>, pub zswpout: Option<u64>, pub zswpwb: Option<u64>, pub thp_fault_alloc: Option<u64>, pub thp_collapse_alloc: Option<u64>, pub thp_swpout: Option<u64>, pub thp_swpout_fallback: Option<u64>, pub numa_pages_migrated: Option<u64>, pub numa_pte_updates: Option<u64>, pub numa_hint_faults: Option<u64>,
}
Expand description

memory.stat (as of linux v7.3)

Fields§

§anon: Option<u64>§file: Option<u64>§kernel: Option<u64>§kernel_stack: Option<u64>§pagetables: Option<u64>§sec_pagetables: Option<u64>§percpu: Option<u64>§sock: Option<u64>§vmalloc: Option<u64>§shmem: Option<u64>§zswap: Option<u64>§zswapped: Option<u64>§zswap_incomp: Option<u64>§file_mapped: Option<u64>§file_dirty: Option<u64>§file_writeback: Option<u64>§swapcached: Option<u64>§anon_thp: Option<u64>§file_thp: Option<u64>§shmem_thp: Option<u64>§inactive_anon: Option<u64>§active_anon: Option<u64>§inactive_file: Option<u64>§active_file: Option<u64>§unevictable: Option<u64>§slab_reclaimable: Option<u64>§slab_unreclaimable: Option<u64>§slab: Option<u64>§hugetlb: Option<u64>§workingset_refault_anon: Option<u64>§workingset_refault_file: Option<u64>§workingset_activate_anon: Option<u64>§workingset_activate_file: Option<u64>§workingset_restore_anon: Option<u64>§workingset_restore_file: Option<u64>§workingset_nodereclaim: Option<u64>§pgdemote_kswapd: Option<u64>§pgdemote_direct: Option<u64>§pgdemote_khugepaged: Option<u64>§pgdemote_proactive: Option<u64>§pgsteal_kswapd: Option<u64>§pgsteal_direct: Option<u64>§pgsteal_khugepaged: Option<u64>§pgsteal_proactive: Option<u64>§pgscan_kswapd: Option<u64>§pgscan_direct: Option<u64>§pgscan_khugepaged: Option<u64>§pgscan_proactive: Option<u64>§pgrefill: Option<u64>§pgpromote_success: Option<u64>§pgscan: Option<u64>§pgsteal: Option<u64>§pswpin: Option<u64>§pswpout: Option<u64>§pgfault: Option<u64>§pgmajfault: Option<u64>§pgactivate: Option<u64>§pgdeactivate: Option<u64>§pglazyfree: Option<u64>§pglazyfreed: Option<u64>§swpin_zero: Option<u64>§swpout_zero: Option<u64>§zswpin: Option<u64>§zswpout: Option<u64>§zswpwb: Option<u64>§thp_fault_alloc: Option<u64>§thp_collapse_alloc: Option<u64>§thp_swpout: Option<u64>§thp_swpout_fallback: Option<u64>§numa_pages_migrated: Option<u64>§numa_pte_updates: Option<u64>§numa_hint_faults: Option<u64>

Implementations§

Source§

impl Stat

Source

pub fn anon(&self) -> u64

Returns the value of anon, or the default value if anon is unset.

Source

pub fn file(&self) -> u64

Returns the value of file, or the default value if file is unset.

Source

pub fn kernel(&self) -> u64

Returns the value of kernel, or the default value if kernel is unset.

Source

pub fn kernel_stack(&self) -> u64

Returns the value of kernel_stack, or the default value if kernel_stack is unset.

Source

pub fn pagetables(&self) -> u64

Returns the value of pagetables, or the default value if pagetables is unset.

Source

pub fn sec_pagetables(&self) -> u64

Returns the value of sec_pagetables, or the default value if sec_pagetables is unset.

Source

pub fn percpu(&self) -> u64

Returns the value of percpu, or the default value if percpu is unset.

Source

pub fn sock(&self) -> u64

Returns the value of sock, or the default value if sock is unset.

Source

pub fn vmalloc(&self) -> u64

Returns the value of vmalloc, or the default value if vmalloc is unset.

Source

pub fn shmem(&self) -> u64

Returns the value of shmem, or the default value if shmem is unset.

Source

pub fn zswap(&self) -> u64

Returns the value of zswap, or the default value if zswap is unset.

Source

pub fn zswapped(&self) -> u64

Returns the value of zswapped, or the default value if zswapped is unset.

Source

pub fn zswap_incomp(&self) -> u64

Returns the value of zswap_incomp, or the default value if zswap_incomp is unset.

Source

pub fn file_mapped(&self) -> u64

Returns the value of file_mapped, or the default value if file_mapped is unset.

Source

pub fn file_dirty(&self) -> u64

Returns the value of file_dirty, or the default value if file_dirty is unset.

Source

pub fn file_writeback(&self) -> u64

Returns the value of file_writeback, or the default value if file_writeback is unset.

Source

pub fn swapcached(&self) -> u64

Returns the value of swapcached, or the default value if swapcached is unset.

Source

pub fn anon_thp(&self) -> u64

Returns the value of anon_thp, or the default value if anon_thp is unset.

Source

pub fn file_thp(&self) -> u64

Returns the value of file_thp, or the default value if file_thp is unset.

Source

pub fn shmem_thp(&self) -> u64

Returns the value of shmem_thp, or the default value if shmem_thp is unset.

Source

pub fn inactive_anon(&self) -> u64

Returns the value of inactive_anon, or the default value if inactive_anon is unset.

Source

pub fn active_anon(&self) -> u64

Returns the value of active_anon, or the default value if active_anon is unset.

Source

pub fn inactive_file(&self) -> u64

Returns the value of inactive_file, or the default value if inactive_file is unset.

Source

pub fn active_file(&self) -> u64

Returns the value of active_file, or the default value if active_file is unset.

Source

pub fn unevictable(&self) -> u64

Returns the value of unevictable, or the default value if unevictable is unset.

Source

pub fn slab_reclaimable(&self) -> u64

Returns the value of slab_reclaimable, or the default value if slab_reclaimable is unset.

Source

pub fn slab_unreclaimable(&self) -> u64

Returns the value of slab_unreclaimable, or the default value if slab_unreclaimable is unset.

Source

pub fn slab(&self) -> u64

Returns the value of slab, or the default value if slab is unset.

Source

pub fn hugetlb(&self) -> u64

Returns the value of hugetlb, or the default value if hugetlb is unset.

Source

pub fn workingset_refault_anon(&self) -> u64

Returns the value of workingset_refault_anon, or the default value if workingset_refault_anon is unset.

Source

pub fn workingset_refault_file(&self) -> u64

Returns the value of workingset_refault_file, or the default value if workingset_refault_file is unset.

Source

pub fn workingset_activate_anon(&self) -> u64

Returns the value of workingset_activate_anon, or the default value if workingset_activate_anon is unset.

Source

pub fn workingset_activate_file(&self) -> u64

Returns the value of workingset_activate_file, or the default value if workingset_activate_file is unset.

Source

pub fn workingset_restore_anon(&self) -> u64

Returns the value of workingset_restore_anon, or the default value if workingset_restore_anon is unset.

Source

pub fn workingset_restore_file(&self) -> u64

Returns the value of workingset_restore_file, or the default value if workingset_restore_file is unset.

Source

pub fn workingset_nodereclaim(&self) -> u64

Returns the value of workingset_nodereclaim, or the default value if workingset_nodereclaim is unset.

Source

pub fn pgdemote_kswapd(&self) -> u64

Returns the value of pgdemote_kswapd, or the default value if pgdemote_kswapd is unset.

Source

pub fn pgdemote_direct(&self) -> u64

Returns the value of pgdemote_direct, or the default value if pgdemote_direct is unset.

Source

pub fn pgdemote_khugepaged(&self) -> u64

Returns the value of pgdemote_khugepaged, or the default value if pgdemote_khugepaged is unset.

Source

pub fn pgdemote_proactive(&self) -> u64

Returns the value of pgdemote_proactive, or the default value if pgdemote_proactive is unset.

Source

pub fn pgsteal_kswapd(&self) -> u64

Returns the value of pgsteal_kswapd, or the default value if pgsteal_kswapd is unset.

Source

pub fn pgsteal_direct(&self) -> u64

Returns the value of pgsteal_direct, or the default value if pgsteal_direct is unset.

Source

pub fn pgsteal_khugepaged(&self) -> u64

Returns the value of pgsteal_khugepaged, or the default value if pgsteal_khugepaged is unset.

Source

pub fn pgsteal_proactive(&self) -> u64

Returns the value of pgsteal_proactive, or the default value if pgsteal_proactive is unset.

Source

pub fn pgscan_kswapd(&self) -> u64

Returns the value of pgscan_kswapd, or the default value if pgscan_kswapd is unset.

Source

pub fn pgscan_direct(&self) -> u64

Returns the value of pgscan_direct, or the default value if pgscan_direct is unset.

Source

pub fn pgscan_khugepaged(&self) -> u64

Returns the value of pgscan_khugepaged, or the default value if pgscan_khugepaged is unset.

Source

pub fn pgscan_proactive(&self) -> u64

Returns the value of pgscan_proactive, or the default value if pgscan_proactive is unset.

Source

pub fn pgrefill(&self) -> u64

Returns the value of pgrefill, or the default value if pgrefill is unset.

Source

pub fn pgpromote_success(&self) -> u64

Returns the value of pgpromote_success, or the default value if pgpromote_success is unset.

Source

pub fn pgscan(&self) -> u64

Returns the value of pgscan, or the default value if pgscan is unset.

Source

pub fn pgsteal(&self) -> u64

Returns the value of pgsteal, or the default value if pgsteal is unset.

Source

pub fn pswpin(&self) -> u64

Returns the value of pswpin, or the default value if pswpin is unset.

Source

pub fn pswpout(&self) -> u64

Returns the value of pswpout, or the default value if pswpout is unset.

Source

pub fn pgfault(&self) -> u64

Returns the value of pgfault, or the default value if pgfault is unset.

Source

pub fn pgmajfault(&self) -> u64

Returns the value of pgmajfault, or the default value if pgmajfault is unset.

Source

pub fn pgactivate(&self) -> u64

Returns the value of pgactivate, or the default value if pgactivate is unset.

Source

pub fn pgdeactivate(&self) -> u64

Returns the value of pgdeactivate, or the default value if pgdeactivate is unset.

Source

pub fn pglazyfree(&self) -> u64

Returns the value of pglazyfree, or the default value if pglazyfree is unset.

Source

pub fn pglazyfreed(&self) -> u64

Returns the value of pglazyfreed, or the default value if pglazyfreed is unset.

Source

pub fn swpin_zero(&self) -> u64

Returns the value of swpin_zero, or the default value if swpin_zero is unset.

Source

pub fn swpout_zero(&self) -> u64

Returns the value of swpout_zero, or the default value if swpout_zero is unset.

Source

pub fn zswpin(&self) -> u64

Returns the value of zswpin, or the default value if zswpin is unset.

Source

pub fn zswpout(&self) -> u64

Returns the value of zswpout, or the default value if zswpout is unset.

Source

pub fn zswpwb(&self) -> u64

Returns the value of zswpwb, or the default value if zswpwb is unset.

Source

pub fn thp_fault_alloc(&self) -> u64

Returns the value of thp_fault_alloc, or the default value if thp_fault_alloc is unset.

Source

pub fn thp_collapse_alloc(&self) -> u64

Returns the value of thp_collapse_alloc, or the default value if thp_collapse_alloc is unset.

Source

pub fn thp_swpout(&self) -> u64

Returns the value of thp_swpout, or the default value if thp_swpout is unset.

Source

pub fn thp_swpout_fallback(&self) -> u64

Returns the value of thp_swpout_fallback, or the default value if thp_swpout_fallback is unset.

Source

pub fn numa_pages_migrated(&self) -> u64

Returns the value of numa_pages_migrated, or the default value if numa_pages_migrated is unset.

Source

pub fn numa_pte_updates(&self) -> u64

Returns the value of numa_pte_updates, or the default value if numa_pte_updates is unset.

Source

pub fn numa_hint_faults(&self) -> u64

Returns the value of numa_hint_faults, or the default value if numa_hint_faults is unset.

Trait Implementations§

Source§

impl Clone for Stat

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Stat

Source§

impl Debug for Stat

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Stat

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Eq for Stat

Source§

impl Hash for Stat

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Message for Stat

Source§

fn encoded_len(&self) -> usize

Returns the encoded length of the message without a length delimiter.
Source§

fn clear(&mut self)

Clears the message, resetting all fields to their default.
Source§

fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>
where Self: Sized,

Encodes the message to a buffer. Read more
Source§

fn encode_to_vec(&self) -> Vec<u8> ⓘ
where Self: Sized,

Encodes the message to a newly allocated buffer.
Source§

fn encode_length_delimited( &self, buf: &mut impl BufMut, ) -> Result<(), EncodeError>
where Self: Sized,

Encodes the message with a length-delimiter to a buffer. Read more
Source§

fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘ
where Self: Sized,

Encodes the message with a length-delimiter to a newly allocated buffer.
Source§

fn decode(buf: impl Buf) -> Result<Self, DecodeError>
where Self: Default,

Decodes an instance of the message from a buffer. Read more
Source§

fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>
where Self: Default,

Decodes a length-delimited instance of the message from the buffer.
Source§

fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>
where Self: Sized,

Decodes an instance of the message from a buffer, and merges it into self. Read more
Source§

fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>
where Self: Sized,

Decodes a length-delimited instance of the message from buffer, and merges it into self.
Source§

impl PartialEq for Stat

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Stat

Auto Trait Implementations§

§

impl Freeze for Stat

§

impl RefUnwindSafe for Stat

§

impl Send for Stat

§

impl Sync for Stat

§

impl Unpin for Stat

§

impl UnsafeUnpin for Stat

§

impl UnwindSafe for Stat

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.