pub struct StaticSlabPool<const PAGE_SIZE: usize = 4096, const N: usize = 1> { /* private fields */ }Expand description
Default static slab-pool wrapper used by EII integrators.
Implementations§
Trait Implementations§
Source§impl<const PAGE_SIZE: usize, const N: usize> SlabPoolTrait for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize, const N: usize> SlabPoolTrait for StaticSlabPool<PAGE_SIZE, N>
Source§fn current_slab(&self) -> &dyn SlabTrait
fn current_slab(&self) -> &dyn SlabTrait
Return the slab belonging to the current CPU.
Source§fn owner_slab(&self, cpu_idx: usize) -> &dyn SlabTrait
fn owner_slab(&self, cpu_idx: usize) -> &dyn SlabTrait
Return the owner slab for the given CPU.
Source§fn current_cpu_id(&self) -> usize
fn current_cpu_id(&self) -> usize
Logical CPU id of the current CPU.
Source§fn alloc(&self, layout: Layout) -> AllocResult<SlabAllocResult>
fn alloc(&self, layout: Layout) -> AllocResult<SlabAllocResult>
Allocate one object from the current CPU’s slab.
Auto Trait Implementations§
impl<const PAGE_SIZE: usize = 4096, const N: usize = 1> !Freeze for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize = 4096, const N: usize = 1> !RefUnwindSafe for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize, const N: usize> Send for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize, const N: usize> Sync for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize, const N: usize> Unpin for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize, const N: usize> UnsafeUnpin for StaticSlabPool<PAGE_SIZE, N>
impl<const PAGE_SIZE: usize, const N: usize> UnwindSafe for StaticSlabPool<PAGE_SIZE, N>
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