Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create WIT definitions for lunatic's host functions #86

Open
bkolobara opened this issue Jan 21, 2022 · 0 comments
Open

Create WIT definitions for lunatic's host functions #86

bkolobara opened this issue Jan 21, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@bkolobara
Copy link
Contributor

We should provide *.wit files for lunatic's host functions. WIT (WebAssembly Interface Types) files are definitions of higher level types and function signatures that describe an API that the Wasm host is exporting and the guest is importing. It can also be an interface between two Wasm modules in the component model.

For example, the WASI functions that are provided by lunatic have a formal spec in the *.wit file format, but none of the other ones (networking, process spawning, messages, ...) do. I think we should also create them! However, this will result in some breaking API changes.

There are two main benefits in providing such a spec:

Even if we don't end up using the automatically generated bindings, following the canonical ABI proposal for host functions will result in wider support from guests. Lunatic is already exposing an unspecified inconsistent ABI that is fairly similar to the proposal. So, why not go a step further and just use the standard everyone is using?

This will also give us an opportunity to go over all the existing host functions and remove inconsistencies.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant