pub struct PosixShmProviderBackendBuddy { /* private fields */ }Expand description
A buddy_system_allocator backend based on POSIX shared memory.
This API has been marked as unstable: it works as advertised, but it may be changed in a future release.
buddy_system_allocator is the fastest allocator ever. The weak side is it's low memry efficiency and
higher fragmentation as opposed to talc (which is treated as the universal default for zenoh SHM)Implementations§
Source§impl PosixShmProviderBackendBuddy
impl PosixShmProviderBackendBuddy
Sourcepub fn builder<Layout>(
layout: Layout,
) -> PosixShmProviderBackendBuddyBuilder<Layout>
pub fn builder<Layout>( layout: Layout, ) -> PosixShmProviderBackendBuddyBuilder<Layout>
Get the builder to construct a new instance
This API has been marked as unstable: it works as advertised, but it may be changed in a future release.
Trait Implementations§
Source§impl ShmProviderBackend for PosixShmProviderBackendBuddy
impl ShmProviderBackend for PosixShmProviderBackendBuddy
Source§fn alloc(&self, layout: &MemoryLayout) -> ChunkAllocResult
fn alloc(&self, layout: &MemoryLayout) -> ChunkAllocResult
Allocate the chunk of desired size. Read more
Source§fn free(&self, chunk: &ChunkDescriptor)
fn free(&self, chunk: &ChunkDescriptor)
Deallocate the chunk. Read more
Source§fn defragment(&self) -> usize
fn defragment(&self) -> usize
Defragment the memory. Read more
Source§fn layout_for(&self, layout: MemoryLayout) -> Result<MemoryLayout, ZLayoutError>
fn layout_for(&self, layout: MemoryLayout) -> Result<MemoryLayout, ZLayoutError>
Check and calculate suitable layout for layout. Read more
Source§impl WithProtocolID for PosixShmProviderBackendBuddy
impl WithProtocolID for PosixShmProviderBackendBuddy
fn id(&self) -> ProtocolID
Auto Trait Implementations§
impl !Freeze for PosixShmProviderBackendBuddy
impl RefUnwindSafe for PosixShmProviderBackendBuddy
impl Send for PosixShmProviderBackendBuddy
impl Sync for PosixShmProviderBackendBuddy
impl Unpin for PosixShmProviderBackendBuddy
impl UnwindSafe for PosixShmProviderBackendBuddy
Blanket Implementations§
Source§impl<Source> AccessAs for Source
impl<Source> AccessAs for Source
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