Allocation within caller-owned writable memory regions
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Erik Inkinen e7c100508a
All checks were successful
CI / markdown (push) Successful in 20s
CI / rust (push) Successful in 1m44s
feat: Resize allocations within their original region
Integrate the human-reviewed change from lib-owned-region#6.
2026-11-12 18:56:16 +02:00
.github ci: Declare policy helper and output boundaries 2026-11-07 18:25:00 +02:00
src feat: Resize allocations within their original region 2026-10-30 13:53:52 +02:00
.editorconfig Initial commit 2026-10-17 09:17:55 +02:00
.gitignore Initial commit 2026-10-17 09:17:55 +02:00
.markdownlint-cli2.yaml Initial commit 2026-10-17 09:17:55 +02:00
ARCHITECTURE.md feat: Resize allocations within their original region 2026-10-30 13:53:52 +02:00
Cargo.toml feat: Allocate within explicitly owned backing regions 2026-10-30 13:53:52 +02:00
CODE_OF_CONDUCT.md Initial commit 2026-10-17 09:17:55 +02:00
CONTRIBUTING.md feat: Allocate within explicitly owned backing regions 2026-10-30 13:53:52 +02:00
LICENSE Initial commit 2026-10-17 09:17:55 +02:00
README.md feat: Resize allocations within their original region 2026-10-30 13:53:52 +02:00
ROADMAP.md feat: Resize allocations within their original region 2026-10-30 13:53:52 +02:00
rustfmt.toml Initial commit 2026-10-17 09:17:55 +02:00
SECURITY.md Initial commit 2026-10-17 09:17:55 +02:00

lib-owned-region

Allocate within one caller-owned writable memory region without reserving backing storage, invoking a service, or depending on another crate.

Purpose of This Repository

ReservedHeap manages one exclusive region with checked free-list geometry. RegionAllocator serializes that primitive behind Rust's GlobalAlloc interface. Its empty handle contains metadata only; callers explicitly install the original region once and retain its backing for every allocation lifetime. Resizing can reuse adjacent free bytes or return a shrunken tail to that same region; reallocation preserves the original allocation when growth is refused.

See ARCHITECTURE.md for ownership, synchronization, failure, and teardown contracts. ROADMAP.md records integration work. The source rustdoc documents each operation and its unsafe preconditions.

Clean-Room Policy

All implementation is EriX-authored. Do not add external crates, copy external implementation code, or generate code that embeds third-party implementation.

License

ISC.

Development Model

Use formatting, strict Clippy, debug and release tests, warning-denied rustdoc, and freestanding no_std checks. See CONTRIBUTING.md for shared review and signed-commit requirements.

Governance Principles

Keep allocation policy separate from memory acquisition and native authority. Coordinate API changes with consumers and preserve original pointer, layout, region, and lifetime requirements.

Library Boundaries

The library registers no global allocator, maps no memory, chooses no fixed heap size, and installs no allocation-error handler. It does not authenticate the caller's backing, retire a mapping, or release a native grant.

Contact

Development is tracked in the EriX organization. Contact the maintainer at admin@erikinkinen.fi.