binaryen
binaryen copied to clipboard
SIMD types and instructions aren't documented in the JS API
I'm reading https://github.com/WebAssembly/binaryen/wiki/binaryen.js-API and I noticed literally none of the SIMD types available (available in the latest version on npm) are documented. Could this be resolved so I'm not just making educated guesses based on the existing types and the instructions themselves?
I obviously couldn't do it myself - if I did, I likely wouldn't be filing this issue.
Also impacted by https://github.com/WebAssembly/binaryen/issues/2677
Yeah, now that the SIMD proposal is finished, it would be good to document this. For now, you can look at src/js/binaryen.js-post.js to see what is available.
FWIW (and this is no replacement for docs), the only SIMD type is v128
and all the instruction names in the API should be the same as the names in the standard text format.
@tlively
FWIW (and this is no replacement for docs), the only SIMD type is v128 and all the instruction names in the API should be the same as the names in the standard text format.
I'm aware - hence the guesswork. I also found https://github.com/AssemblyScript/binaryen.js/ which seems to have, while still wildly far from perfect, better and more up to date documentation, so it might just be better to link to that instead. (I couldn't find any easy links there and just lucked into it through npm.)
Good point, looks like we have links to the AssemblyScript/binaryen.js
site on our README but just for downloading the builds, not the docs. I think a docs link would make sense too? Maybe from our docs page? cc @dcodeIO