Stream: git-wasmtime

Topic: wasmtime / PR #11461 Make garbage collection an `async` ...


view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 19:42):

alexcrichton opened PR #11461 from alexcrichton:gc-async to bytecodealliance:main:

This commit is similar to https://github.com/bytecodealliance/wasmtime/pull/11442 and https://github.com/bytecodealliance/wasmtime/pull/11460 except it's applied to the
garbage collection phase of Wasmtime's GC. Specifically the functions
that actually perform a GC are no longer duplicated across sync, async,
and maybe async versions. There's only one "always async" version and
the root-level crate entrypoints for sync versions assert that async
support is disabled and then use the async version.

Worth noting here is that GC suffers from a preexisting issue described
in https://github.com/bytecodealliance/wasmtime/issues/11409 where it's not sound how a StoreOpaque is widened to acquire
a resource limiter. This commit seemingly makes the issue worse by
adding a few more unsafe blocks, but they're all fundamentally doing
the same thing as before. Fully solving this issue will require making
memory/table creation an async function that takes the limiter as an
argument. Doing this will require further refactoring/code movement so
my goal is to effectively maintain the status quo, but in a slightly
different location, and enable knocking out the unsafe in the future.
In the meantime the previous unsafe block is "lifted higher up" so
it's not quite so deep and should be easier to remove in the future.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 19:42):

alexcrichton requested fitzgen for a review on PR #11461.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 19:42):

alexcrichton requested wasmtime-core-reviewers for a review on PR #11461.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 19:42):

alexcrichton commented on PR #11461:

Note that this is currently built on https://github.com/bytecodealliance/wasmtime/pull/11460 which is in turn built on https://github.com/bytecodealliance/wasmtime/pull/11459

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 21:00):

fitzgen submitted PR review:

Nice

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 21:00):

fitzgen created PR review comment:

s/safe/sound/?

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 21:29):

alexcrichton updated PR #11461.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 21:30):

alexcrichton has enabled auto merge for PR #11461.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 21:44):

alexcrichton updated PR #11461.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 19 2025 at 22:19):

alexcrichton merged PR #11461.


Last updated: Dec 06 2025 at 07:03 UTC