[FRIAM] FW: Partial WebAssembly backend

Owen Densmore owen at backspaces.net
Sat Mar 4 12:56:16 EST 2017


Yup, WebAsm is now enabled in modern browsers, thanks to a stable API for
several releases. It's amazing how quickly this was defined and got
implemented! (Unlike es6 modules, es2015, going on 2 years late!).

An interesting intro:
  https://hacks.mozilla.org/2017/02/a-cartoon-intro-to-webassembly/
Four browsers commit to current API (also above)
  https://lists.w3.org/Archives/Public/public-webassembly/2017Feb/0002.html
.. and it looks like latest dev releases have it turned on by default,
rather than via flags.

It's not gonna kill JavaScript but it may provide entry for other
languages, as long as they can be compiled to LLVM (Low Level Virtual
Machine). The issue is getting the standard libraries converted. C/C++ are
go, as I understand it. I think Fortran too!

   -- Owen

On Sat, Mar 4, 2017 at 9:40 AM, Marcus Daniels <marcus at snoutfarm.com> wrote:

>
>
> -----Original Message-----
> From: binutils-owner at sourceware.org [mailto:binutils-owner at sourceware.org]
> On Behalf Of Pip Cet
> Sent: Saturday, March 04, 2017 9:30 AM
> To: binutils at sourceware.org
> Subject: Partial WebAssembly backend
>
> I'd like to announce a WebAssembly backend for the GNU toolchain
> (binutils, gcc, glibc) that I've been working on for a while.
>
> WebAssembly (https://www.w3.org/community/webassembly/) is an object file
> format for a virtual machine implementing conventional 32-bit
> integer/64-bit floating-point arithmetic. Version 1 has been released on
> February 28 (https://lists.w3.org/Archives/Public/public-
> webassembly/2017Feb/0002.html),
> and enabled in various browsers, including Mozilla.
>
> This binutils port produces and deals with ELF files containing
> WebAssembly code; WebAssembly modules (in the WebAssembly object file
> format) can be output using special linker scripts and -Obinary, but they
> cannot be used as input for any of the binutils programs at present.
>
> (While the gcc port, in particular, makes some decisions that negatively
> affect performance, the binutils port is quite general and should permit
> the assembly, linking, and manipulation of all WebAssembly code, provided
> it is still encapsulated in ELF files).
>
> The code is at https://github.com/pipcet/binutils-gdb, included from the
> larger project at https://github.com/pipcet/asmjs. Some documentation is
> available at https://github.com/pipcet/asmjs/blob/everything/wasm32.org
> (specific to the wasm32 target) and https://github.com/pipcet/
> asmjs/blob/everything/asmjs.org (for all three targets: asmjs, wasm32,
> and wasm64). The GitHub sources include support for using asm.js instead of
> wasm, and some rudimentary support for simulating a 64-bit machine using
> wasm.
>
> I'd appreciate any questions, comments or advice, and in particular I'd
> like to ask whether it is possible in theory to include this backend in the
> standard GNU binutils distribution; some work would be required on my end
> to do that, and I'm not sure it's worth the effort if there is no chance of
> inclusion at the end of the process.
>
> If anyone else has been or is planning to work on a WebAssembly backend,
> it would be great to hear from them, and maybe some of my code could be
> reused for that.
>
> Pip Cet
> ============================================================
> FRIAM Applied Complexity Group listserv
> Meets Fridays 9a-11:30 at cafe at St. John's College
> to unsubscribe http://redfish.com/mailman/listinfo/friam_redfish.com
> FRIAM-COMIC http://friam-comic.blogspot.com/ by Dr. Strangelove
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://redfish.com/pipermail/friam_redfish.com/attachments/20170304/d7eaa645/attachment-0002.html>


More information about the Friam mailing list