Repository navigation
Put all EM_JS/EM_ASM strings in a specific data section - #13443
Conversation
If we find a data segment with the name "em_js", strip it from the binary. Even in debug mode the names given to data segments by clang will always start with ".data." or ".rodata" so there is no risk of normal data ending up in a section with this name. See: emscripten-core/emscripten#13443
If we find a data segment with the name "em_js", strip it from the binary. Even in debug mode the names given to data segments by clang will always start with ".data." or ".rodata" so there is no risk of normal data ending up in a section with this name. See: emscripten-core/emscripten#13443
|
Is it worth working on an EM_JS-specific solution? That is, is there no solution for EM_JS and EM_ASM? |
Sure, I'm just doing it one step at a time. EM_JS is actually quite different to EM_ASM in that the strings don't actually need to have addresses in LLVM sense... so the solution we end up with might look different. But also I do think and EM_JS-only solution is better than nothing. |
|
This part of the change is really a no-brainer (IMHO). It doesn't actually do anything except group the EM_JS strings into a single data section. Even if we never get around to actually purging it on the binaryen side (which I totally think we will) I still think its good for debugging / understandably. |
|
Updated the comment to include plans to further investigate the EM_ASM situation. |
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
If we find a data segment whose entire contents is EM_JS or EM_ASM strings then strip it from the binary. See: emscripten-core/emscripten#13443
This way, once binaryen has extracted that string data it can potentially remove the segment or at least zero it out. Fixes #9366
842309d to
510d924
Compare
This way, once binaryen has extracted that string data
it can potentially remove the segment or at least zero it
out.
Fixes #9366