mnemosyne-memory-core
Core types, constants, size classes, and synchronization primitives for the
Mnemosyne allocator. The library
name is mnemosyne_core; the crates.io package is mnemosyne-memory-core.
This is the foundation crate: every other Mnemosyne crate depends on it, and it
depends on nothing in the workspace. It is #![no_std].
[]
= "0.2"
Contents
policy— theAllocPolicysealed trait and its zero-sized implementations (StandardPolicy,SecurePolicy,HardenedPolicy). Policy selection is a type parameter, so the unused branch is dead code at compile time.types—Page, the free-list types, andAtomicFreeList, the page-local lock-free cross-thread free queue.Pageis pinned to exactly one 64-byte cache line by a layout test.size_class— size-class derivation shared by every allocation path.validation—is_valid_alloc_requestandis_valid_layout_alloc_request, the twoconst fnpredicates every allocation entry point routes through, soMAX_ALLOC_SIZEand the alignment rules have one definition.constants— segment and page geometry (2 MiB segments, 64 KiB pages).sync,loom_shim— synchronization primitives, swappable for loom's model-checked equivalents undercfg(loom).abort— the single authoritative corruption sink.
This crate defines the MemoryBackend contract but implements no backend; see
mnemosyne-backend.
Licensed under MIT OR Apache-2.0.