Allocator and Nyxus owner frontier

Research snapshot: factory 87b7233794da334e03f8fa0b714a9b3cd902efa6, SDK 409a7176096c06c2dd9b7e491e8dc630951e83b4, 5 November 2026. This is a new source audit and planning report, not a new compiler, model-checker or SMT run. Recorded qualification below retains its original identities. No implementation, proof, tool pin or runtime contract changed during this audit.

Status

The next useful step is an ownership/representation handoff, rather than another larger bounded allocator history. Checked metadata transitions do not yet issue or consume the actual live byte capabilities required by Nyxus owners.

Area Recorded checked result Boundary still open
Buddy selection/splitting Actual contiguous selection/removal/split/counter fragment, two Kani harnesses; independently characterized least admissible order and exact bitmap effects Page-bin search, real selected page, complete free/live/reserved partition and returned payload ownership
Deductive buddy contracts At 541b9d21, release pipeline 20 reports/101 goals/258 leaves; acquisition pipeline 25/137/375, including release producers Same-execution conservation covers all 256 cells; ownership is of the header, not its page payload. Totals overlap and must not be added
Global page bins Nine actual native positives/28 covers and exact negatives; separate Verus model with 23 obligations Initial actual pointer/sequence embedding, ownership and completeness of all physically free pages
Logical partition Separate 17-obligation Verus partition model Actual source history, physical ownership, exact live-span cardinality and maximal free-block/search correspondence
Partial slabs Both policies, classes 0/15: ten positives/66 covers; default additionally checks nine independent UNLINK pairs Full chain/cardinality/live-owner invariant, other classes, fresh-span construction and arbitrary histories
Small release Four actual nonfinal harnesses/32 covers; separate four-harness/14-cover final-dispatch model Final model records pre-call observations only; actual buddy/provider release is omitted
Allocation facade Six positives/six covers and two exact controls, fixed fast/invalid/failed direct-resize layouts Successful movement/copy/release, general layouts, zeroing and the Nyxus Allocator wrapper
Nyxus containers Recursive type admission, compiled physical/interpretation contracts and runtime/compile tests No connected formal allocator/container ownership, initialization or destruction theorem

Source/result details: selection, release, acquisition, bins, partition, slabs, release dispatch, UNLINK controls, and facade.

What the current contracts actually supply

Source references below use the frozen SDK: H is the shared allocation engine, N the explicit Nyxus allocator, C (source unavailable) its native collection wrappers and S (source unavailable) the custom shared owner. Line numbers refer to the snapshot above. Proof paths in this report are relative to the factory's verification/ directory.

  • Actual source algorithms are shared. Nyxus imports HintedHeap from the platform (N, lines 4–6). There is no separate Nyxus buddy implementation to prove. Its native backend uses System-owned runs and a process lock (N:169–275); Wasm uses retained extents, a protected heap and a synchronous ready/busy guard (N:300–446). Proving either provider is not proving the other.
  • Universal metadata conservation is genuine but conditional. acquire.rs:59–76 starts after selected-node removal with aligned coordinates, summary consistency, live_spans < u16::MAX and a free-plus-pending bound. It does not require the offset to exclude the reserved first 512 bytes or link the counter to a set of live owned spans. coalesce.rs:183–210 composes the actual nonfinal decrement and coalescing on one Perm<PageHeader>, requiring live_spans > 1. This is not a defective local theorem; the missing facts must come from its caller's representation/resource invariant.
  • Selection itself is not new work. proofs/allocator/kani/buddy_split.rs:6–85 already checks the actual selection prefix and the split. The missing bridge is into the deductive/resource consumer, not another isolated scalar-selection proof.
  • Membership is weaker than completeness. proofs/allocator/verus/global_bins.rs:7–23,290–305 states uniqueness and placement of entries that exist. It does not require every owned page with a free span to occur. Actual search (H:327–355) needs that stronger world invariant, including correct largest-order placement and header liveness.
  • Byte reserve and user initialization differ. A request can be one byte, while its reserved slot is at least eight bytes. Release writes a two-byte free-chain link (H:225–227). A useful allocation token must retain the full reserved stride/padding for the allocator while granting the client only its requested initialized extent. contains is explicitly only a page-domain observation (N:65–68), not such an allocation token.
  • Final slab dispatch is a deliberate model boundary. slab_release_boundary_support.rs:19–38 uses BoundaryHeap and an observation recorder. Its captures cannot establish the real call's physical effects or post-release frames. The actual final path calls H:367–397.
  • Type/ABI admission is not a destruction proof. C (source unavailable):18–96 delegates Vec/Map/Set/Queue to allocator-parameterized standard containers. Its Box/Rc/Weak wrappers similarly retain standard-library ownership dependencies. The NyxusData safety contract (engine-nyxus/src/data.rs:13–34,121–128) requires recursive retained ownership, but source-policy hashes certify identity, not the truth of allocation/drop behavior. S (source unavailable):49–114,262–299 is a smaller custom owner whose initialization/count/drop effects can be examined first.

Five proposed assignments, in dependency order

A1 — Connect an already-owned page to acquisition

First milestone: for one admitted page, connect its actual header/bitmap, reserved prefix, live-span set and bin placement; check the exact selection and removal prefix (H:352–356) and compose the existing split contract. Show the returned interval is aligned, outside the header, disjoint from remaining live spans and represented by exactly one new live token. Separately extend the empty-bin branch through actual INITIAL_FREE initialization (H:332–345).

Use source-erased Creusot clients and current primitive bridges. Existing Kani selection/initial-partition producers are reusable evidence, not a new assumed whole-acquisition law. Scalar trailing-zero contracts may need a narrowly qualified producer bridge. Keep global arbitrary-page completeness explicit if the first result covers one page only. Feasibility: medium; header/body composition is established, actual byte/typed-header resource embedding is the main dependency on the physical-provider track.

Required checks: existing-page and fresh-page valid cases, exhaustion without heap/live-owner mutation, all admissible orders; independent negatives for reserved overlap, lost free coverage, wrong returned interval and missing/duplicate bin membership.

A2 — Complete span release and last-owner return

Consume A1's exact span token. Derive page_base and offset from that token, relate live_spans to live-token cardinality, then join the checked nonfinal coalescing fragment with actual rebinning (H:373–396). For the last token, prove actual unlink then one exact release_pages(page,1) and no later page access. Header permissions must be retired with the page, not kept as a false post-release frame. This replaces the final slab recorder only after its PageSource/resource preconditions are supplied.

Use Creusot resource composition; reuse native local-bin effects and the reviewed global model only with an explicit pointer/resource embedding. Feasibility: medium/high risk at the physical handoff, not a reason to assume release. Check nonlast/last, exhausted/not-exhausted bins and real neighbors. Independent negatives: early release with another live span, duplicate return, wrong base/count and use-after-return. A2 depends on A1 plus the provider's release contract; scalar count subtraction alone cannot justify the last case.

A3 — General slab partition and free-chain preservation

Define one ghost partition of issued slots into live slots and an acyclic, unique free-chain sequence; unissued slots form the bump suffix. Relate live count, bump, chain length and partial-list membership. Connect actual head pop (H:178–193) and release push (H:214–230) to this invariant. Start with a conditional owned span, then consume A1/A2 for construction and final retirement.

Existing full-domain geometry/list results should supply class facts. An independent arithmetic survey of H:537–561 found 77 classes, at most 28 slots, spans up to 32 KiB, and 18 one-slot classes; it is planning arithmetic, not a new Rust proof. Parameterize the invariant by stride/capacity, instead of copying 77 fixtures or unrolling complete histories over a 32-KiB byte image. Prefer deductive induction plus actual local-source correspondence; a separate Verus chain theorem must retain its explicit source-embedding boundary.

Feasibility: medium, subject to the Kani boundary below. Valid cases must include empty/nonmonotone chains, final bump, full→partial and one-slot final release. Independent negatives: cycle, duplicate live/free cell, lost tail, wrong cardinality and mutation of another live slot. Reserve the full stride while tracking only initialized user bytes. Chain cardinality cannot be inferred from the current head/successor harness alone.

A4 — Successful resize/zeroing and the Nyxus Allocator contract

First check one actual fixed-layout direct→direct successful replacement through H:259–292, with disjoint pre-owned runs and an actual observed release callback. Prove the selected-byte prefix min(old.size,new.size), replacement liveness, exact old-run retirement and frames. Then connect N:88–161: zero-sized dangling results, ordinary grow/shrink and failure preservation; the separate Allocator::grow_zeroed path must prove zeroing exactly the added tail. Current six facade harnesses cover only fixed failed/fast/invalid cases.

Use small fixed physical witnesses first, followed by a deductive pointwise copy/tail contract. A conditional provider contract must remain visible; fixture bookkeeping is not proof of physical ownership. Feasibility: medium for a fixed direct move, higher for arbitrary layouts/slab↔direct paths; A1–A3 are dependencies for the latter. Check in-place and moved growth, alignment change, zero length, dirty reused storage and allocation failure. Independent negatives must observe wrong copy/tail bytes or premature old-run release, not inert flags.

A5 — First downstream owner, before whole standard containers

Use existing SharedSlice<u8> as a small pilot (S (source unavailable):49–114,180–208,262–299): layout/header/tail extent, initialized-prefix construction, immutable loans, clone count and nonfinal/final drop. Start with count/layout and nonfinal effects; final deallocation must consume A4's real allocator contract. Generic element destructors/panic paths and the append builder's published/unpublished ranges are later explicit extensions, not silently included in a byte pilot.

Feasibility: medium; actual Cell/raw-tail frontend compatibility should be a small first spike. Validate nonempty/empty owners and multiple aliases; independent negatives for premature/double free, count overflow, publication of uninitialized bytes and mutation under a live immutable borrow. Treat standard Vec/Rc/Weak/B-tree internals as further proof/import dependencies; do not replace them or add runtime ownership tables merely to simplify verification.

Model boundary and work to avoid

The pinned Kani LINK byte-Slab/typed-Heap discrepancy remains EXPERIMENTAL_UNQUALIFIED; the authored six-case comparison and both native compiler outcomes do not establish a general memory-model theorem. Admitted UNLINK pairs are operation-specific. No A1–A5 producer may consume that diagnostic as an allocator fact. Root-cause/representation qualification is a separate assurance-track dependency before expanding affected mixed-owner checks.

Do not repeat the known 90-second complete-page/span probes or symbolic-layout resize timeouts with a larger budget and call that progress. Use exact source fragments, checked branch conditions and one resource carried across calls. Keep ghost tokens, ownership maps and invariants outside product builds. A runtime representation change would require separate SDK review and matched performance qualification; none is proposed or measured here.

Audit validation

Read actual shared heap, Nyxus native/Wasm backends, collection/custom-owner source, proof contracts, extractors and scoped qualification notes. The only executed probe was the finite Python geometry survey described above. No new production defect was established; missing ownership/representation theorems and the existing verifier discrepancy are distinct findings. Documentation/link, research-index and whitespace checks are recorded with this report's commit.