Stream: git-wasmtime

Topic: wasmtime / PR #13513 Finish bindings generation for `(imp...


view this post on Zulip Wasmtime GitHub notifications bot (May 29 2026 at 22:05):

alexcrichton opened PR #13513 from alexcrichton:finish-implements to bytecodealliance:main:

This commit is the final step in finishing up the bindings generation story for bindgen! w.r.t. the (implement ...) component model feature. Namely bindgen! now has the option named_imports: { ... } which generates a new top-level named_imports module with nested modules within it. These nested modules are similar to the default-generated ones except that they additionally take an extra "id" parameter in all trait methods. The add_to_linker function additionally takes both a &Component and a lookup function.

Putting all this together the expected flow is:

Some light tests are added throughout this showcasing the various capabilities. This notably added a new ComponentExtern::is_implements method to peform semver-matching automatically so hosts can generate bindings with one version and still accept implements with other slightly different but compatible versions.

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

view this post on Zulip Wasmtime GitHub notifications bot (May 29 2026 at 22:05):

alexcrichton requested pchickey for a review on PR #13513.

view this post on Zulip Wasmtime GitHub notifications bot (May 29 2026 at 22:05):

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

view this post on Zulip Wasmtime GitHub notifications bot (May 29 2026 at 23:05):

github-actions[bot] added the label wasmtime:api on PR #13513.

view this post on Zulip Wasmtime GitHub notifications bot (May 29 2026 at 23:16):

tschneidereit commented on PR #13513:

One thing I didn't think about when we discussed this yesterday: how much overhead does this introduce for hosts with large numbers of components loaded? (I'm not sure how much of a real alternative to this design there is, but I'd at least like to understand the costs a bit better.)

view this post on Zulip Wasmtime GitHub notifications bot (Jun 01 2026 at 14:12):

alexcrichton commented on PR #13513:

I always forget to correct that as well, but what hosts are doing right now is actually a linker-per-engine plus an instance-pre-per-component. This PR doesn't change the latter, still an instance-pre-per-component, and the main difference is that when creating an instance-pre-per-component the host will likely .clone() the per-engine linker, add more items, then create the instance pre, then discard the temporary linker. I wouldn't expect any negligible resource increase or decrease from this.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 01 2026 at 14:50):

tschneidereit commented on PR #13513:

I wouldn't expect any negligible resource increase or decrease from this.

Assuming you mean s/negligible/non-negligible/: great! :)

view this post on Zulip Wasmtime GitHub notifications bot (Jun 01 2026 at 15:01):

alexcrichton commented on PR #13513:

Oops, yes!

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

alexcrichton updated PR #13513.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 03 2026 at 16:34):

:thumbs_up: pchickey submitted PR review.

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

alexcrichton added PR #13513 Finish bindings generation for (implements ..) to the merge queue

view this post on Zulip Wasmtime GitHub notifications bot (Jun 03 2026 at 17:06):

:check: alexcrichton merged PR #13513.

view this post on Zulip Wasmtime GitHub notifications bot (Jun 03 2026 at 17:06):

alexcrichton removed PR #13513 Finish bindings generation for (implements ..) from the merge queue


Last updated: Jul 29 2026 at 05:03 UTC