Lin Clark on WebAssembly

In this entry, I'll be going over another Software Engineering episode. In this occasion,  Lin Clark will give us a glimpse into WebAssembly.

Lin Clark is a web comic artist (I looked up a few, not smart enough to laugh) as well as a "tinkerer" (as her Twitter bio states) on WebAssembly. She starts off by explaining the purpose of WebAssembly, which is essentially fast and reliable performance. Being employed in the web development industry,

Clark describes that WebAssembly's main goal is to optimize Javascript. It is no surprise that the clunkiness of Javascript results in a loss of efficiency when running on browsers. Efficient code is, of course necessary to run web-based games and apps without any stutter or lag, and so WebAssembly helps in accomplishing the needed optimization.

So WebAssembly seems to have it's roots in ASM.JS, which is a tool for running assembly code on the virtual machine that Javascript runs in, I'm not sure if it's an add-on, but certainly it adds functionality.  WebAssembly itself is a compiler language, made so that web applications run adequately on all browsers. This seems like a more sound approach than hacking together code that runs better on a certain browser but may fall apart in another.

A great limitation that WebAssembly has, however, is that it only has ints and floats, stored in heaps. So right off the bat I wouldn't find it simple, by any means. Clark mentions tools such as Wasm Bindgen, which makes working web WA easier. The only downside would be to learn Rust...

Overall, WebAssembly sounds like a necessary tool for improving performance. I may not have much experience with building compilers, but working with Javascript and 3D browser applications does make me realize the current limitations. WebAssembly strives for efficiency, and although it does seem quite "bare bones" right now, I'm sure that it's a step in the right direction.

Comments