Stream: git-wasmtime

Topic: wasmtime / issue #6213 How to dump the machine code after...


view this post on Zulip Wasmtime GitHub notifications bot (Apr 14 2023 at 14:17):

hungryzzz opened issue #6213:

Hi, I want to dump the compiled machine code but I don't find the related option.
How could I do it? Thank you!

view this post on Zulip Wasmtime GitHub notifications bot (Apr 14 2023 at 15:57):

alexcrichton commented on issue #6213:

There's no "official" way to do this but for debugging what you can do is call Module::serialize (or wasmtime compile) and then run objdump -S on the output. While not "officially supported" we're unlikely to change that since Wasmtime developers themselves frequently use it for debugging.

view this post on Zulip Wasmtime GitHub notifications bot (Apr 14 2023 at 15:57):

alexcrichton closed issue #6213:

Hi, I want to dump the compiled machine code but I don't find the related option.
How could I do it? Thank you!

view this post on Zulip Wasmtime GitHub notifications bot (Apr 14 2023 at 17:58):

jameysharp commented on issue #6213:

Depending on what you need it for, you might also find wasmtime explore helpful; it'll produce an HTML-format dump correlating wasm instructions with the machine code that they were compiled into.

view this post on Zulip Wasmtime GitHub notifications bot (Apr 14 2023 at 19:36):

alexcrichton commented on issue #6213:

Oh thank you @jameysharp I keep forgetting to mention that as well! And it's probably a lot more useful than objdump to bood!


Last updated: Dec 23 2024 at 12:05 UTC