cowboyd
cowboyd•2w ago

How to load DWARF debugging symbols from WASM modules when running `deno --inspect`

I'm trying to step through some WASM code that I've imported as a module with the debugger when using deno --inspect. While this does work with the raw WASM, it does not actually display any of the debug symbols that are included when you compile with -g I've set up a project to demonstrate the issue: https://github.com/cowboyd/deno-wasm-debug I'm not sure exactly why this is not working in Deno, but it could very well be that it is not loading the custom devtools extension that is require to load the debug symbols. Has anybody else gotten this to work, or know of a way that it could?
GitHub
GitHub - cowboyd/deno-wasm-debug: Try to figure out how to load DWA...
Try to figure out how to load DWARF debug symbols for WASM module when using deno --inspect - cowboyd/deno-wasm-debug
C/C++ DevTools Support (DWARF) - Chrome Web Store
DevTools Plugin for debugging C/C++ WebAssembly applications (using DWARF debug information). BETA version, use at your own risk.
4 Replies
cowboyd
cowboydOP•2w ago
@hansl and @Performance Queen Skye discussed this (briefly) back in June of 2021, but I was not able to find any resolution https://discord.com/channels/684898665143206084/689420767620104201/851517571101622292
Bubbles
Bubbles•2w ago
Uhh what
cowboyd
cowboydOP•2w ago
It was like three years back so no expectation that you would recall 🙂 but I linked the discussion 👆 It's a pretty niche issue, so I wanted to loop in anybody that might even be tangentially interested in it.
Bubbles
Bubbles•2w ago
so you are compiling a C program with emcc passing the -g(3) flag so that it outputs debug symbols and these work fine in the browser (and devtools for browser) but breaks when loading the same bin in deno and opening devtools?

Did you find this page helpful?