Large __wasm_apply_data_relocs function #17374
Unanswered
alexander-veselov
asked this question in
Q&A
Replies: 1 comment 3 replies
-
This function is proportional to the number of data relocation in you have in your program, which occur when static data contains address (e.g. What version of emscripten are you using? We made some improvements in this area recently so please try the latest vesion? If you can use We do have a tracking bug for this issue: llvm/llvm-project#55608 |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We were finally able to somehow run the application using dynamic libraries. But we decided that we want to make some of the libraries static, since we don't plan to load them using dlopen.
Everything works if you build all the libraries statically (without using MAIN_MODULE). It also works if all libraries are dynamic (using MAIN_MODULE).
But if we try to make some libraries dynamic and some static, then the following runtime error occurs:
Runtime error:
Uncaught (in promise) RuntimeError: Aborted(CompileError: WebAssembly.instantiate(): size 10345817 > maximum function size 7654321 @+5462385). Build with -sASSERTIONS for more info.
I found that the problem is in
__wasm_apply_data_relocs
function.Command:
wasm-objdump -j code -x file.wasm
Output:
- func[901] size=10345817 <__wasm_apply_data_relocs>
Can this be fixed somehow? What affects the size of this function?
Beta Was this translation helpful? Give feedback.
All reactions