News for hackers. Stuff that matters.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by tyingq on Saturday April 24, 2021 @06:43PM (#26928846)
It seems like it's headed that way. At the moment, it's only really practical to generate WASM from compiled languages, or really small languages, like Lua. And your interfaces to the browser (and thus, the outside world) itself are pretty limited, so still lots of javascript involved.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by vvanders on Saturday April 24, 2021 @06:55PM (#26928912)
Can confirm that Lua does run in WASM in the browser: https://github.com/vvanders/wasm_lua

I sometimes wonder what the world would be like if Lua had zero based indices and saw a bit broader adoption. It's such an easy language to embed/extends although QuickJS looks like it's going to give it a run for the money in the long term given the similar goals on ease of embedding.

I wonder if anyone has compiled QuickJS to WASM and run it in the browser.

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by nathcd on Saturday April 24, 2021 @07:24PM (#26929079)
> I wonder if anyone has compiled QuickJS to WASM and run it in the browser.

Fabrice Bellard actually did it himself here: http://numcalc.com/

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by heavyset_go on Saturday April 24, 2021 @10:26PM (#26929868)
If your language is supported by LLVM, then Emscripten can compile it to WASM.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by tyingq on Saturday April 24, 2021 @10:50PM (#26929972)
Yes, but for interpreted language 'X', are the created artifacts of a practical size to send down the wire for an actual production site? The idea being that as WASM adds higher level primitives, that size gets smaller.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by heavyset_go on Sunday April 25, 2021 @07:50PM (#26937864)
Sorry, I misread your comment. I thought you wrote that only "small languages", or Lua, can be compiled to WASM.