Comment by flohofwoe

4 days ago

Because Javascript would need to change a lot to better support compiled languages (for instance adding 'proper' separate integer and float types, but that's just the tip of the iceberg). This means extending the ECMAScript standard with features only few web developers care about, increased complexity in JS engines, and potential design-conflicts for new JS features between 'compile-friendly' vs 'human-friendly'. With WASM, the WASM peeps can focus on WASM and the JS peeps can focus on JS.

Are you saying JavaScript is not turing complete, so it can't do everything that other languages can?

  • Turing complete doesn't say anything about runtime performance or compile times.

    • I haven't used asm.js and compared it to WASM myself, so I'm curious to understand your statements here.

      Regarding runtime performance, you said "Javascript isn't drastically slower than WASM in most situations."

      So are you saying that the reason WASM exists is to have faster compile times than asm.js, or marginally faster runtime perf in most situations, or drastically faster runtime perf in rare situations?

      1 reply →