You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Was wondering what your thoughts are on how it should work. There seems to be a lot of different approaches that kind of work and it's not clear what is the most sensible one. Some options are listed below:
add a ptr type to WasmType that generates an isize with corresponding load/store instructions
the abi has hard coded offsets so it seems that the parser crate needs to know if it's 32/64bit
add a parameter to the abi
the abi is currently hardcoded for every function, so it's not clear how to inject the pointer width
add a configurable pointer width in addition to Interface and AbiVariant, the Generator trait passes an enum WasmPtr { I32, I64 }
dealing with handles:
it is not clear if the handle index should always be an i32 on 64bit platforms, or if this is an additional configuration option (as on native it is just a ptr)
the handle cannot be an isize as the host ptr width is irrelevant, so it probably has to be generic. making it generic leaks abi details, as the handle is part of the public api
The text was updated successfully, but these errors were encountered:
I don't think much thought has gone into the specifics of what this would look like in the code itself, but naively I would expect that the WasmType enum would change but instead there'd be some sort of configuration passed in when generating bindings whether it's for 32-bit or 64-bit. There aren't a ton of 64-bit use cases right now so this is still up-in-the-air.
As for handles I don't believe there has been much discussion about whether they should always use 32-bit indices or 64-bit indices.
I'm going to close this in favor of WebAssembly/component-model#22 since memory64 hasn't been defined relative to the component model yet and that will need to happen before support can be implemented here.
Was wondering what your thoughts are on how it should work. There seems to be a lot of different approaches that kind of work and it's not clear what is the most sensible one. Some options are listed below:
enum WasmPtr { I32, I64 }
dealing with handles:
The text was updated successfully, but these errors were encountered: