pub struct PagerStats {
pub hits: u64,
pub misses: u64,
pub bytes_read: u64,
pub bytes_served: u64,
pub evictions: u64,
}Expand description
What paging cost, in the terms the planner priced it in.
Fields§
§hits: u64Expert reads served from RAM.
misses: u64Expert reads that went to disk.
bytes_read: u64Bytes actually read from storage.
bytes_served: u64Bytes served from the cache (what the disk did not have to move).
evictions: u64Experts dropped to stay inside the budget.
Implementations§
Source§impl PagerStats
impl PagerStats
Sourcepub fn hit_rate(&self) -> f64
pub fn hit_rate(&self) -> f64
Share of expert reads served without touching disk, in 0..=1.
The number that decides whether paging is viable for a given model: a router that spreads uniformly over 288 experts has almost no reuse to exploit and this stays near zero however large the budget, whereas a peaked router turns most of the IO term into memcpy.
Trait Implementations§
Source§impl Clone for PagerStats
impl Clone for PagerStats
impl Copy for PagerStats
Source§impl Debug for PagerStats
impl Debug for PagerStats
Source§impl Default for PagerStats
impl Default for PagerStats
impl Eq for PagerStats
Source§impl PartialEq for PagerStats
impl PartialEq for PagerStats
impl StructuralPartialEq for PagerStats
Auto Trait Implementations§
impl Freeze for PagerStats
impl RefUnwindSafe for PagerStats
impl Send for PagerStats
impl Sync for PagerStats
impl Unpin for PagerStats
impl UnsafeUnpin for PagerStats
impl UnwindSafe for PagerStats
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more