Skip to content

Add --print-function-map to print out a map of function index to name#2155

Merged
kripken merged 4 commits intomasterfrom
esm
Jun 1, 2019
Merged

Add --print-function-map to print out a map of function index to name#2155
kripken merged 4 commits intomasterfrom
esm

Conversation

@kripken
Copy link
Copy Markdown
Member

@kripken kripken commented May 31, 2019

This can be useful for interpreting a stack trace from a production environment where names did not exist on the client. Emscripten will use this to implement emcc --emit-symbol-map for the wasm backend.

@kripken kripken requested review from dschuff and tlively May 31, 2019 21:17
@kripken kripken merged commit 7306f60 into master Jun 1, 2019
@kripken kripken deleted the esm branch June 1, 2019 02:57
kripken added a commit to emscripten-core/emscripten that referenced this pull request Jun 12, 2019
To solve this, we emit -g on all intermediate operations on the wasm, preserving the function names. We then emit the symbol map at the very end, and also remove names from the binary if they are not needed there (doesn't make much sense to have names in both the binary and out, but we don't disallow that).

Fixes #8686

Depends on WebAssembly/binaryen#2155
belraquib pushed a commit to belraquib/emscripten that referenced this pull request Dec 23, 2020
…-core#8724)

To solve this, we emit -g on all intermediate operations on the wasm, preserving the function names. We then emit the symbol map at the very end, and also remove names from the binary if they are not needed there (doesn't make much sense to have names in both the binary and out, but we don't disallow that).

Fixes emscripten-core#8686

Depends on WebAssembly/binaryen#2155
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 this pull request may close these issues.

2 participants