Skip to main content

SeizeAllocator

Struct SeizeAllocator 

Source
pub struct SeizeAllocator<P: LeafPolicy> { /* private fields */ }
Expand description

Unified seize-based allocator for all leaf policies.

Implementations§

Source§

impl<P: LeafPolicy> SeizeAllocator<P>

Source

pub const fn new() -> Self

Create a new allocator.

Trait Implementations§

Source§

impl<P: Debug + LeafPolicy> Debug for SeizeAllocator<P>

Source§

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

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

impl<P: LeafPolicy> Default for SeizeAllocator<P>

Source§

fn default() -> Self

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

impl<P: LeafPolicy + 'static> TreeAllocator<P> for SeizeAllocator<P>

Source§

unsafe fn retire_leaf(&self, ptr: *mut LeafNode15<P>, guard: &LocalGuard<'_>)

Retire a leaf node for deferred reclamation. Read more
Source§

unsafe fn retire_internode_erased(&self, ptr: *mut u8, guard: &LocalGuard<'_>)

Retire an internode for deferred reclamation. Read more
Source§

fn teardown_tree(&self, root_ptr: *mut u8)

Teardown all reachable nodes at tree drop.
Source§

fn alloc_leaf_direct( &self, is_root: bool, is_layer_root: bool, ) -> *mut LeafNode15<P>

Allocate a leaf node directly from the pool and initialize it in-place.
Source§

fn alloc_internode_direct(&self, height: u32) -> *mut u8

Allocate an internode directly from the pool and initialize it in-place.
Source§

fn alloc_internode_direct_root(&self, height: u32) -> *mut u8

Allocate an internode as a root node directly from the pool.
Source§

fn alloc_internode_direct_for_split( &self, parent_version: &NodeVersion, height: u32, ) -> *mut u8

Allocate an internode for a split operation directly from the pool.
Source§

impl<P: LeafPolicy> Send for SeizeAllocator<P>

Source§

impl<P: LeafPolicy> Sync for SeizeAllocator<P>

Auto Trait Implementations§

§

impl<P> Freeze for SeizeAllocator<P>

§

impl<P> RefUnwindSafe for SeizeAllocator<P>
where P: RefUnwindSafe,

§

impl<P> Unpin for SeizeAllocator<P>
where P: Unpin,

§

impl<P> UnsafeUnpin for SeizeAllocator<P>

§

impl<P> UnwindSafe for SeizeAllocator<P>
where P: UnwindSafe,

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> 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.