5 ms·
What's stopping a compile of Erlang to JS via LLVM and Emscripten and just taking the expected performance hit?
by pmarreck 10y ago
What's stopping a compile of Erlang to JS via LLVM and Emscripten and just taking the expected performance hit?
- Xixi 10y agoErlang doesn't compile to machine code, but to bytecode that runs into the Erlang VM. So you would probably have to run the Erlang VM on top of javascript... I'm not sure whether it's possible, but it sure sounds heavy.
- int_19h 10y agoWith WebAssembly, you should be able to compile the Erlang VM itself to it.
- bryanjos 10y agoThere is the LLVM backend in Erlang as of version 17. I haven't seen much info on it. I haven't seen anyone try to go the whole process from Erlang code to LLVM to Emscripten to JavaScript. I am interested to know what hurdles there might be, performance, etc.