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
They're almost 25% of the size of the .text section itself, wow!
These sections are occasionally useful to have in a *.cwasm when profiling. Native profilers/debuggers can often use these sections and think that a dynamic library is loaded here when the profiler doesn't otherwise have native jit integration (e.g. via perfmap, jitdump, etc). In that sense I think it's useful to still emit these by default, but we should have a Config::* option for removing them.
In theory it should be possible to just directly remove them entirely and nothing should break in Wasmtime itself. Famous last words though. I'm not 100% sure how we'd do this but I suspect we'd use the object crate a bit differently and maybe assign the same empty string to all symbol names or somehow not assign symbols at all (I'm not sure if that's possible?).
If something in Wasmtime does break from the removal of these symbols we should fix that to not rely on symbol names and instead use something in the compiled metadata here and there instead. For example function indices, offsets, etc. Exactly what the solution might look like depends on what's using a symbol (if any) and in what context it's using it.
The text was updated successfully, but these errors were encountered:
In #10285 it was shown that sections such as
.symtab
,.strtab
, and.shstrtab
account for a non-trivial portion of the size of an object file:They're almost 25% of the size of the
.text
section itself, wow!These sections are occasionally useful to have in a
*.cwasm
when profiling. Native profilers/debuggers can often use these sections and think that a dynamic library is loaded here when the profiler doesn't otherwise have native jit integration (e.g. via perfmap, jitdump, etc). In that sense I think it's useful to still emit these by default, but we should have aConfig::*
option for removing them.In theory it should be possible to just directly remove them entirely and nothing should break in Wasmtime itself. Famous last words though. I'm not 100% sure how we'd do this but I suspect we'd use the
object
crate a bit differently and maybe assign the same empty string to all symbol names or somehow not assign symbols at all (I'm not sure if that's possible?).If something in Wasmtime does break from the removal of these symbols we should fix that to not rely on symbol names and instead use something in the compiled metadata here and there instead. For example function indices, offsets, etc. Exactly what the solution might look like depends on what's using a symbol (if any) and in what context it's using it.
The text was updated successfully, but these errors were encountered: