3 ms·
It's great that eg asyncify is upstreamed to binaryen/LLVM. My issue with Emscripten is that it's quite challenging to fix bugs in the wrapper Javascript code i
by jitl 4y ago
It's great that eg asyncify is upstreamed to binaryen/LLVM. My issue with Emscripten is that it's quite challenging to fix bugs in the wrapper Javascript code it generates. I spent a few nights trying to understand how to change the compiler output so I could import the Emscripten result as an ES6 module in both a browser and Node 16+. The way this works is unfortunately 1000s of lines of `if` statements that decide whether or not to concatenate this or that helper into a file, and all the little helper snippets may or may not call into each other. Some of the concatenation is in Python, some of it is in Javascript. I eventually gave up without making any upstreamable progress.
Relevant github issue: https://github.com/emscripten-core/emscripten/issues/11792 https://github.com/emscripten-core/emscripten/issues/11792
A quote from that thread:
> Btw, this issue shouldn't be tagged good-first-bug, because fixing it will require a substantial overhaul of how Emscripten sets up its imports and organises its startup code. There are several ways it can be accomplished, but it really needs direction from one of the project leads.
It doesn't seem like there's any progress here :(