wasmtime icon indicating copy to clipboard operation
wasmtime copied to clipboard

component model: async host function & embedding support

Open pchickey opened this issue 3 years ago • 4 comments

Based on #5065.

This PR adds the async suite of variations on Linker::wrap_func, Func::call, TypedFunc::call, and the various instantiate functions, for use in async Rust contexts.

This ends up being pretty simple: all of the async store machinery from core wasmtime is straightforward to reuse here.

I created a new test suite at tests/all/component_model/async.rs to smoke test the new functionality.

pchickey avatar Oct 14 '22 00:10 pchickey

Subscribe to Label Action

cc @peterhuene

This issue or pull request has been labeled: "wasmtime:api"

Thus the following users have been cc'd because of the following labels:

  • peterhuene: wasmtime:api

To subscribe or unsubscribe from this label, edit the .github/subscribe-to-label.json configuration file.

Learn more.

github-actions[bot] avatar Oct 14 '22 01:10 github-actions[bot]

I've double-checked bits and pieces internally and I think this should generally be good to go. I'm always somewhat wary of async since it's got unsafe underpinnings with fibers and whatnot but I'm at least for now confident enough in this that I'd be happy to merge.

alexcrichton avatar Oct 17 '22 15:10 alexcrichton

Thanks! I just need to write some tests.

pchickey avatar Oct 17 '22 16:10 pchickey

Subscribe to Label Action

cc @fitzgen

This issue or pull request has been labeled: "fuzzing"

Thus the following users have been cc'd because of the following labels:

  • fitzgen: fuzzing

To subscribe or unsubscribe from this label, edit the .github/subscribe-to-label.json configuration file.

Learn more.

github-actions[bot] avatar Oct 18 '22 00:10 github-actions[bot]