Repository navigation
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MemoryManager reopening and refused growth currently force consumers to duplicate private layout validation and bucket accounting. This adds checked reopening, persisted-layout inspection and fallible growth at the manager owner.
try_initrejects nonempty foreign/corrupt/unsupported memory without resetting it, retaining existing geometry. The explicit bucket-size variant also rejects geometry mismatch. Checked reopening constructs the manager from the validated bucket lists instead of decoding the table twice. Existingloaduses the same validator.VirtualMemory::try_growreturns typed overflow, bucket exhaustion, backing refusal and reentrancy errors. Backing capacity is reserved before bucket assignment or virtual-size publication. Checked growth also rejects zero cached geometry from an existing unchecked constructor. TheMemory::growimplementation uses that same assignment owner and returns -1 on refusal, replacing the prior backing-refusal panic after bucket mutation. Stable layout and collection contents are unchanged. Backing traps/partial writes retain the backing's own execution semantics.Validation at upstream base b5d1650:
Qualified PR head: b1dd27b (zero-geometry follow-up included).
clippy --tests --benches -- -D clippy::allpass.Remaining qualification: the upstream-selected Rust 1.84 compiler is not installed here; mdbook and its plugins are not prepared; no macOS-native, installed IC upgrade or IC instruction/size claim is made. Strict Rust 1.99 native rustdoc and Clippy encounter existing README conditional-link/ASCII-diagram lint errors outside this patch; original failed logs are retained. The root has no Cargo example targets, so its
--examplescheck was a no-op rather than example qualification.IC Memory will retain its current published-dependency guards until an accepted published API and exact consumer layout/corruption/growth/installed qualification permit removing them. No downstream dependency/version selection, release or stable-data reset accompanies this draft.