WebAssembly / WebAssembly/binaryen
binaryen.js wasm-opt commandline tool
Nobody has claimed this yet.
- Dominant language
- WebAssembly
- Stars
- 8.6k
- Forks
- 885
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 69
Description
Currently binaryen.js provides a JS API. Maybe we could also make a commandline version, basically a port of wasm-opt so it runs in node.js. Using NODERAWFS it can have filesystem access, and using node pthreads it even should be almost as fast.
I'm imagining something like
$ npm install -g binaryen
$ wasm-opt input.wasm -O -o output.wasm
This might help with distributing builds. See e.g. https://github.com/WebAssembly/binaryen/pull/2405#issuecomment-548529341 for issues with getting a single native build to run on all linuxes etc. - with a node.js build we should be easily portable to anywhere node.js runs + more secure! :)
cc @dcodeIO
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the binaryen.js package and the existing wasm-opt command-line tool, then check the Emscripten NODERAWFS and node pthreads references mentioned in the issue. Define how the npm-installed command should accept input.wasm, optimization options, and output.wasm; done means the command works in Node.js and is portable across supported Node.js environments.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, wasm
- Domain
- cli, compilers
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100