-
Notifications
You must be signed in to change notification settings - Fork 21
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
wasi 64 support by adding _wasm64 API sets #44
Comments
Maybe Also maybe the |
can you give me an example where it's much easier? |
I am currently assisting in the integration of a 64-bit API into an existing project VM named WAVM. This VM automatically generates function signatures based on their definitions. Previously, I had to handle interfacing with LLVM, which was cumbersome. However, by simply adding "_i64" postfix APIs, I no longer need to deal with that complexity. Also, most of the entire tooling systems are built based on assuming address and size being i32. By adding new API names to 64 bit only would not break any existing tools but reusing them. (Well, you just add new APIs) It just makes it much easier to implement. By the way, if you want to run wasm32 and wasm64 apps in a VM like this, new APIs could do them both easily.
Maybe. |
Changed to wasm64 |
generate signatures from which definitions?
well, this issue is about core wasm import names, right? my question is, what's wrong with having the following two functions with the same name?
|
yeah. Two functions with the same name are much harder to implement than just duplicating APIs. For example, try to support 32 bit and 64 bit wasm at the same time is much harder to implement. Plus existing tools are all assume address are 32 bits, they all have to be fixed which is too much work. If we duplicate the APIs for 64 bit version, these tools will still work without changing, but by adding new APIs. |
for some reasons specific to wavm, you mean?
what kind of tools are you talking about, for example? |
also, i guess function name alone is not enough to introduce 64-bit variant of wasi. |
Rename new traps.wast test -> traps0.wast
This seems like an issue that should be continued in the WASI repo. Closing this here since I don't think it relates to the core memory64 spec. |
See:
WebAssembly/wasi-libc#444
I think the wasi API can have its _i64 version to implement ptr for 64 bit instead of making the API the same. This will make things much easier to support for VM that needs to run for both 32 and 64.
We do it transparently in the wasi-libc so vm does not need to change anything.
The text was updated successfully, but these errors were encountered: