Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

geseparate_dwarf, symbol files, and external_debug_info reference #11516

Closed
pfaffe opened this issue Jun 29, 2020 · 5 comments · Fixed by #11521
Closed

geseparate_dwarf, symbol files, and external_debug_info reference #11516

pfaffe opened this issue Jun 29, 2020 · 5 comments · Fixed by #11521

Comments

@pfaffe
Copy link
Collaborator

pfaffe commented Jun 29, 2020

Compiling with -geseparate_dwarf=foo.wasm currently has the effect of generating a foo.wasm file containing all DWARF data, and will also insert an external_debug_info custom section into the code module containing a string 'foo.wasm'.

It would be great to increase flexibility here. For instance, what if I want to point to the symbol module by absolute URL? I'd propose supporting a mapping syntax such as for --embed-file: -gseparate_dwarf=./foo.wasm@http://.../foo.wasm

@kripken
Copy link
Member

kripken commented Jun 29, 2020

Sounds reasonable to me, and the syntax sounds ok too.

@dschuff what do you think?

@dschuff
Copy link
Member

dschuff commented Jun 29, 2020

The idea seems reasonable to me too. So the idea is that the bit before the @ would be the debuginfo output file in the local filesystem and the bit after it would appear in the external debug info custom section?

@kripken
Copy link
Member

kripken commented Jun 30, 2020

Yes, I think that's the suggestion.

@dschuff
Copy link
Member

dschuff commented Jul 1, 2020

Another thing it might be worthwhile to support might be something like a GNU build ID, which uniquely identifies a build. That way the debugger can use whatever means it wants to locate the debug info, and the build ID can go into the external debug info section.

@dschuff
Copy link
Member

dschuff commented Jul 1, 2020

(this was actually suggested in WebAssembly/tool-conventions#133)

kripken added a commit that referenced this issue Jul 28, 2020
In `-gseparate-dwarf` mode the debug info is in a file on the side,
while the main file has a URL to it. This allows customizing that URL
so that the debug file can be hosted in a custom location relative to
the main file.

fixes #11516
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants