-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Do we still need EMIT_EMSCRIPTEN_METADATA? #12231
Comments
@rianhunter what do you think? |
@AndrewScheidecker: Apparently wavm is relying (or reportedly relying) on Do you know of any remaining reasons why you still need the emscripten_metadata today? I'm hoping modern emscripten-built standalone wasm modules don't need this to be executed. |
This allows us to stop depending wasm-emscripten-finalize to write staticBump which in turn will allow us to stop exporting `__data_end`. As a side effect of this the staticBump information is no longer available in the normal linking mode which means we can't include dynamic_base in EMSCRIPTEN_METADATA anymore. One more nail in the coffin for EMSCRIPTEN_METADATA. See #12231
This allows us to stop depending wasm-emscripten-finalize to write staticBump which in turn will allow us to stop exporting `__data_end`. As a side effect of this the staticBump information is no longer available in the normal linking mode which means we can't include dynamic_base in EMSCRIPTEN_METADATA anymore. One more nail in the coffin for EMSCRIPTEN_METADATA. See #12231
This allows us to stop depending wasm-emscripten-finalize to write staticBump which in turn will allow us to stop exporting `__data_end`, once we update binaryen. As a side effect of this the static bump information is no longer available in the normal linking mode which means we can't include dynamic_base in EMSCRIPTEN_METADATA anymore. One more nail in the coffin for EMSCRIPTEN_METADATA. See #12231
This allows us to stop depending wasm-emscripten-finalize to write staticBump which in turn will allow us to stop exporting `__data_end`, once we update binaryen. As a side effect of this the static bump information is no longer available in the normal linking mode which means we can't include dynamic_base in EMSCRIPTEN_METADATA anymore. One more nail in the coffin for EMSCRIPTEN_METADATA. See #12231
This allows us to stop depending wasm-emscripten-finalize to write staticBump which in turn will allow us to stop exporting `__data_end`, once we update binaryen. As a side effect of this the static bump information is no longer available in the normal linking mode which means we can't include dynamic_base in EMSCRIPTEN_METADATA anymore. One more nail in the coffin for EMSCRIPTEN_METADATA. See #12231
I changed WAVM to not require |
Now WAVM still needs -s EMIT_EMSCRIPTEN_METADATA=1 -s STANDALONE_WASM=1, it seems nothing changed. |
In what sense does it still need this setting? Does it stop working you don't specify this setting? How exactly? |
Ah yes, it looks like wavm needs to have the check removed still. @AndrewScheidecker can you reply here when the check is removed and then I can go ahead and remove the metadata stuff from the emscripten side? |
Thanks for the report @ERICXUCHI. I previously made it work, but I missed an error if you don't explicitly specify an ABI on the |
We have been warning about the deprecation of this setting for about a year now (since 2.0.9). As explained in #12231, the major use cases for this metadata are no longer valid since the embedder should on longer need to know the memory layout of the module (since the memory and table are both created and setup within the wasm module these days). Fixes: #12231
We have been warning about the deprecation of this setting for about a year now (since 2.0.9). As explained in #12231, the major use cases for this metadata are no longer valid since the embedder should on longer need to know the memory layout of the module (since the memory and table are both created and setup within the wasm module these days). Fixes: #12231
We have been warning about the deprecation of this setting for about a year now (since 2.0.9). As explained in #12231, the major use cases for this metadata are no longer valid since the embedder should on longer need to know the memory layout of the module (since the memory and table are both created and setup within the wasm module these days). Fixes: #12231
We have been warning about the deprecation of this setting for about a year now (since 2.0.9). As explained in #12231, the major use cases for this metadata are no longer valid since the embedder should on longer need to know the memory layout of the module (since the memory and table are both created and setup within the wasm module these days). Fixes: #12231
We have been warning about the deprecation of this setting for about a year now (since 2.0.9). As explained in #12231, the major use cases for this metadata are no longer valid since the embedder should on longer need to know the memory layout of the module (since the memory and table are both created and setup within the wasm module these days). Fixes: #12231
When this was originally conceived it was necessary because the embedder required
access to information about the memory and table layout that was not otherwise
available. Emscripten would extra this information during wasm-emscripten-finalize
but other tools couldn't do that.
Since then we have moved away from a model that required the embedder to know
the memory layout and sbrk() and malloc() are now always fully internal to the wasm
module.
For this reason I'm proposing the remove the memory layout information from the
metadata section (because actually we are moving to world emscripten doesn't know
this statically either), and possible the entire EMIT_EMSCRIPTEN_METADATA
option?
The text was updated successfully, but these errors were encountered: