| Crates.io | wasm-edit |
| lib.rs | wasm-edit |
| version | 0.1.7 |
| created_at | 2022-11-01 10:17:44.583955+00 |
| updated_at | 2023-05-27 17:05:10.228568+00 |
| description | Edit and instrument already compiled Wasm binaries |
| homepage | |
| repository | https://github.com/xtuc/wasm-edit |
| max_upload_size | |
| id | 702745 |
| size | 22,057 |
Edit and instrument already compiled Wasm binaries
Moved to https://github.com/xtuc/wasm-coredump.
cargo install wasm-edit
Change the initial memory amount (in pages):
wasm-edit edit-memory --initial-memory=1000 < input.wasm > output.wasm
memory.growTrace calls to the memory.grow instruction:
wasm-edit instrument-memory < input.wasm > output.wasm
Requires Wasi, but doesn't require any change on the host. Tested with Rust and theoretically working with C/C++ (clang).
Some Wasm binaries have very recursive flow of control, increase the maximum stack size:
$ ulimit -s 160000