You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm a compiler writer and exploring using binaryen as the backend for a new language I am working on (not going through llvm). I'm trying to figure out how to make this debuggable. I have line/column/file info already and I see (using the c-api) that I can set expression offsets and generate source maps. That's working just fine. However, except for browsers, every wasm runtime I've seen only supports DWARF for debugging. Is there a way to emit the DWARF info with binaryen? Maybe I'm missing something but I can't figure out how to generate it. Could someone either tell me if this is not supported though it looks like it is after reading through this issue, or provide a hello world style example of how this can be done?
The text was updated successfully, but these errors were encountered:
Binaryen has some DWARF support, but limited, and focused only on passing through and rewriting DWARF as needed.
Instead, what I'd recommend is this:
Use source maps in Binaryen.
Use a tool to convert source maps to DWARF for wasm runtimes that only support DWARF.
The second tool might already exist - I think I've heard of one - but I'm not sure offhand (the opposite direction definitely exists already, and is not that complex, so hopefully source maps to DWARF could be simple as well).
I'm a compiler writer and exploring using binaryen as the backend for a new language I am working on (not going through llvm). I'm trying to figure out how to make this debuggable. I have line/column/file info already and I see (using the c-api) that I can set expression offsets and generate source maps. That's working just fine. However, except for browsers, every wasm runtime I've seen only supports DWARF for debugging. Is there a way to emit the DWARF info with binaryen? Maybe I'm missing something but I can't figure out how to generate it. Could someone either tell me if this is not supported though it looks like it is after reading through this issue, or provide a hello world style example of how this can be done?
The text was updated successfully, but these errors were encountered: