2 ms·
This looks very useful for now, but shouldn't we be trying to get LLVM-based native client standardized for the long term?
by nitrogen 16y ago
This looks very useful for now, but shouldn't we be trying to get LLVM-based native client standardized for the long term?
- lautis 16y agoIf we wanted to have LLVM-based native clients, Emscripten would definitely be needed. Distributing binaries isn't feasible as they aren't portable. Chrome would like to address this by distributing LLVM bitcode[1] and then compile this to native binary using LLVM. Portable Native Clients were introduced as an idea one year ago, but AFAIK there hasn't been much development, mostly because LLVM itself isn't very portable. If native clients would be the path for future web apps, we can't reasonably expect the whole world to switch to LLVM in one night. There would have to be some fallback. As both Portable Native Clients and Emscripten work on LLVM bitcode, Emscripten would be the natural choice. [1] LLVM's name for their intermediate language, low-level bytecode
- ieefransi 16y agoHow are they not portable when translated to javascript ? Granted, this will probably never run Quake in the browser, but if you want a SHA256 hash translated to javascript ... I seriously doubt there's a better tool. All the difficult C stuff instantly useable from javascript, from GWT, from ... That's got to be a boon, right ?
- bzbarsky 16y agoOne problem is that last I checked LLVM is not really all that portable across different hardware architectures (e.g. you can't use the same LLVM bitcode for both x86 and AMD64 code generation; you can't use the same LLVM bitcode for both little-endian and big-endian hardware, etc, etc).