Struct CacheParameter

pub struct CacheParameter { /* private fields */ }
Expand description

Information about an individual cache in the hierarchy.

§Platforms

🟡 AMD ✅ Intel

Implementations§

§

impl CacheParameter

pub fn cache_type(&self) -> CacheType

Cache Type

§Platforms

✅ AMD ✅ Intel

pub fn level(&self) -> u8

Cache Level (starts at 1)

§Platforms

✅ AMD ✅ Intel

pub fn is_self_initializing(&self) -> bool

Self Initializing cache level (does not need SW initialization).

§Platforms

✅ AMD ✅ Intel

pub fn is_fully_associative(&self) -> bool

Fully Associative cache

§Platforms

✅ AMD ✅ Intel

pub fn max_cores_for_cache(&self) -> usize

Maximum number of addressable IDs for logical processors sharing this cache

§Platforms

✅ AMD ✅ Intel

pub fn max_cores_for_package(&self) -> usize

Maximum number of addressable IDs for processor cores in the physical package

§Platforms

❌ AMD ✅ Intel

pub fn coherency_line_size(&self) -> usize

System Coherency Line Size (Bits 11-00)

§Platforms

✅ AMD ✅ Intel

pub fn physical_line_partitions(&self) -> usize

Physical Line partitions (Bits 21-12)

§Platforms

✅ AMD ✅ Intel

pub fn associativity(&self) -> usize

Ways of associativity (Bits 31-22)

§Platforms

✅ AMD ✅ Intel

pub fn sets(&self) -> usize

Number of Sets (Bits 31-00)

§Platforms

✅ AMD ✅ Intel

pub fn is_write_back_invalidate(&self) -> bool

Write-Back Invalidate/Invalidate (Bit 0) False: WBINVD/INVD from threads sharing this cache acts upon lower level caches for threads sharing this cache. True: WBINVD/INVD is not guaranteed to act upon lower level caches of non-originating threads sharing this cache.

§Platforms

✅ AMD ✅ Intel

pub fn is_inclusive(&self) -> bool

Cache Inclusiveness (Bit 1) False: Cache is not inclusive of lower cache levels. True: Cache is inclusive of lower cache levels.

§Platforms

✅ AMD ✅ Intel

pub fn has_complex_indexing(&self) -> bool

Complex Cache Indexing (Bit 2) False: Direct mapped cache. True: A complex function is used to index the cache, potentially using all address bits.

§Platforms

❌ AMD ✅ Intel

Trait Implementations§

§

impl Clone for CacheParameter

§

fn clone(&self) -> CacheParameter

Returns a copy of the value. Read more
1.0.0 · Source§

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

Performs copy-assignment from source. Read more
§

impl Debug for CacheParameter

§

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

Formats the value using the given formatter. Read more
§

impl PartialEq for CacheParameter

§

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

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

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

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl Copy for CacheParameter

§

impl Eq for CacheParameter

§

impl StructuralPartialEq for CacheParameter

Auto Trait Implementations§

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, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.