GuestHeap: SharedMemory accessor + napi bump + Cargo.lock (ECO-416) - #6822
Open
Arshia001 wants to merge 2 commits into
Open
GuestHeap: SharedMemory accessor + napi bump + Cargo.lock (ECO-416)#6822Arshia001 wants to merge 2 commits into
Arshia001 wants to merge 2 commits into
Conversation
Arshia001
force-pushed
the
napi-value-scope-rework
branch
from
July 28, 2026 14:31
45ddbed to
efb5e20
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a public accessor on SharedMemory to expose its backing VMSharedMemory handle, enabling embedders to access the underlying shared-memory representation directly (e.g., for store-independent workflows).
Changes:
- Expose
SharedMemory::vm_shared_memory()returning a reference to the backingVMSharedMemory. - Document intended cross-thread/store-free usage patterns for the returned handle.
Comment on lines
+78
to
+84
| /// The backing VM shared-memory handle. | ||
| /// | ||
| /// Clones of the handle share the same underlying allocation, so an | ||
| /// embedder can keep a clone and operate on the memory (e.g. grow it via | ||
| /// [`LinearMemory::grow`]) from any thread without holding a store. | ||
| /// | ||
| /// [`LinearMemory::grow`]: wasmer_vm::LinearMemory::grow |
Arshia001
force-pushed
the
napi-value-scope-rework
branch
from
July 28, 2026 14:54
efb5e20 to
b2b5a4e
Compare
Arshia001
force-pushed
the
napi-value-scope-rework
branch
from
July 28, 2026 16:10
b2b5a4e to
3ee4915
Compare
Lets embedders keep a clonable, store-free handle to a shared linear memory so they can operate on it (e.g. grow) from any thread. Needed by wasmer-napi to claim guest-memory pages from host-side code that runs on V8 GC threads without Store access. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…(offset-allocator) (ECO-416)
Arshia001
force-pushed
the
napi-value-scope-rework
branch
from
August 4, 2026 13:56
3ee4915 to
f35909d
Compare
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.
Stack 4/4 (wasmer) — final; matches local state. Base:
wasmer-v8-imports-bridge-fixes.Wasmer-side of the GuestHeap work:
lib/api: expose the backingVMSharedMemoryonSharedMemoryso an embedder can grow a shared memory store-free from any threadoffset-allocatordependencySee wasmerio/napi#43.⚠️ Final PR of the stack; not yet mergeable. Relates to ECO-416.