Stream: git-wasmtime

Topic: wasmtime / PR #10870 Start moving away from using `Stored...


view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:38):

alexcrichton edited PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:45):

alexcrichton edited PR #10870:

This PR is a series of commits which is intended to lead up to the conclusion of removing usage of Stored<T> from wasmtime exports. This is intended to be an internal refactoring of the implementation guts of Wasmtime that doesn't have an API-level impact on users of Wasmtime. The motivations for this change are:

While the first bullet here is pretty concrete the second is pretty nebulous. The original motivation was myself working in the wasip3-prototyping branch and brainstorming ways to reduce the amount of unsafety. That led me to wanting to stop using *mut ComponentInstance for example and instead use wasmtime::component::Instance but it was pretty awkward to do so. While none of that has to do with the core wasm bits being changed here I wanted to game out what such changes might look like. Additionally I also wanted to ensure that the chasm between the style of implementation of core wasm and components does not diverge further than it already has.

This PR is a draft PR since it's pretty large and I'll be wanting to split it up over time. I'm going to peel off commits from this PR into separate PRs and land those separately, but I wanted to have this open as a sort of "north star" in case folks are interested to see where this is going.

Sequence-wise this is organized as going through each of the exported items from core wasm modules to remove their usage of Stored<T> one at a time. This will eventually culminate in removing Stored<T> for wasmtime::Instance which will fully migrate core wasm bits away from Stored<T>. Status-wise here's the progress

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:45):

alexcrichton commented on PR #10870:

Sorry I hit submit too soon and I've now actually filled out the description/title for anyone interested.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:46):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:47):

alexcrichton commented on PR #10870:

I'll also clarify, I plan on using this to push lots of commit to, so if anyone would prefer please feel free to unsubscribe from this PR as it may be a bit noisy.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:52):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 15:59):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 18:28):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 18:32):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 18:34):

alexcrichton edited PR #10870:

This PR is a series of commits which is intended to lead up to the conclusion of removing usage of Stored<T> from wasmtime exports. This is intended to be an internal refactoring of the implementation guts of Wasmtime that doesn't have an API-level impact on users of Wasmtime. The motivations for this change are:

While the first bullet here is pretty concrete the second is pretty nebulous. The original motivation was myself working in the wasip3-prototyping branch and brainstorming ways to reduce the amount of unsafety. That led me to wanting to stop using *mut ComponentInstance for example and instead use wasmtime::component::Instance but it was pretty awkward to do so. While none of that has to do with the core wasm bits being changed here I wanted to game out what such changes might look like. Additionally I also wanted to ensure that the chasm between the style of implementation of core wasm and components does not diverge further than it already has.

This PR is a draft PR since it's pretty large and I'll be wanting to split it up over time. I'm going to peel off commits from this PR into separate PRs and land those separately, but I wanted to have this open as a sort of "north star" in case folks are interested to see where this is going.

Sequence-wise this is organized as going through each of the exported items from core wasm modules to remove their usage of Stored<T> one at a time. This will eventually culminate in removing Stored<T> for wasmtime::Instance which will fully migrate core wasm bits away from Stored<T>. Status-wise here's the progress

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

alexcrichton updated PR #10870.

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

alexcrichton edited PR #10870:

This PR is a series of commits which is intended to lead up to the conclusion of removing usage of Stored<T> from wasmtime exports. This is intended to be an internal refactoring of the implementation guts of Wasmtime that doesn't have an API-level impact on users of Wasmtime. The motivations for this change are:

While the first bullet here is pretty concrete the second is pretty nebulous. The original motivation was myself working in the wasip3-prototyping branch and brainstorming ways to reduce the amount of unsafety. That led me to wanting to stop using *mut ComponentInstance for example and instead use wasmtime::component::Instance but it was pretty awkward to do so. While none of that has to do with the core wasm bits being changed here I wanted to game out what such changes might look like. Additionally I also wanted to ensure that the chasm between the style of implementation of core wasm and components does not diverge further than it already has.

This PR is a draft PR since it's pretty large and I'll be wanting to split it up over time. I'm going to peel off commits from this PR into separate PRs and land those separately, but I wanted to have this open as a sort of "north star" in case folks are interested to see where this is going.

Sequence-wise this is organized as going through each of the exported items from core wasm modules to remove their usage of Stored<T> one at a time. This will eventually culminate in removing Stored<T> for wasmtime::Instance which will fully migrate core wasm bits away from Stored<T>. Status-wise here's the progress

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 20:23):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 30 2025 at 22:04):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (May 31 2025 at 01:33):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 02 2025 at 18:15):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 02 2025 at 20:50):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 02 2025 at 23:10):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 02 2025 at 23:56):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 03 2025 at 04:47):

alexcrichton updated PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 03 2025 at 14:41):

alexcrichton closed without merge PR #10870.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 03 2025 at 14:41):

alexcrichton commented on PR #10870:

Final bits here split into https://github.com/bytecodealliance/wasmtime/pull/10908 and https://github.com/bytecodealliance/wasmtime/pull/10909, so closing now.


Last updated: Dec 06 2025 at 06:05 UTC