Skip to content

Instantly share code, notes, and snippets.

View eqrion's full-sized avatar
💭
Parental leave

Ryan Hunt eqrion

💭
Parental leave
View GitHub Profile
@eqrion
eqrion / dotnet-wasm-disassembly.md
Created March 4, 2020 16:38
dotnet.wasm disassembly
rhunt@rhunt-mac~/s/m/g/j/s/obj-debug> dist/bin/js -i wasm/shell.js 2> dotnet.json
js> m = wasmCompile('dotnet.wasm')
js> c = wasmExtractCode(m)
...
js> os.file.writeTypedArrayToFile('dotnet.bin', c.code);
js> printErr(JSON.stringify(c.segments))
js> quit()
rhunt@rhunt-mac~/s/m/g/j/s/obj-debug> ndisasm -b64 dotnet.bin > dotnet.as