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

Works with wit-bindgen? #170

Open
7sDream opened this issue Feb 23, 2023 · 3 comments
Open

Works with wit-bindgen? #170

7sDream opened this issue Feb 23, 2023 · 3 comments

Comments

@7sDream
Copy link

7sDream commented Feb 23, 2023

I saw somewhere last year that wit-bindgen can be used together with wasmtime's golang binding, but when I just went to the wit bindgen repo, I found that after switching to the component model, the implementation of the host side handed over to each runtime.

For now, the origin Rust wasmtime crate supports it, but is it possible to use it in wasmtime-go?

@alexcrichton
Copy link
Member

Not currently, no. Work will eventually be done in this repository to support the component model and *.wit-based bindgen, but for now there are not current plans to execute on that. If you're interested though assistance in implementing this would be appreciated!

@7sDream
Copy link
Author

7sDream commented Feb 24, 2023

I see.

We have some ideas about using WASM to build a subsequent business code dynamic distribution platform. I think It is necessary to reuse some type and define how to transfer between guest and host code using raw number type.

It is still in the early research stage, I am not particularly familiar with WASM too, but It seems that component model (and wit IDL) is the upcoming standard to define these things, right? If so, I think I can try to look into it after serval weeks and try help integrate it in wasmtime-go.

I will read some document about WASM first recently, thanks for your help.

@alexcrichton
Copy link
Member

Indeed the component model is generally the standard for this sort of thing. You might want to take a look at the wit-bindgen repository and the TinyGo guest generator to get a feel for what the Go bindings for the component model might look like roughly.

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

No branches or pull requests

2 participants