Hop, Skip, Jump: Implementing a concurrent interpreter with Promises
This talk will discuss the challenges posed by implementing Hopper. It will investigate the Promises/A+ specification and how our implementation cannot be fully compatible with the spec while providing all of the necessary functionality, and our various attempts at developing our own extensions on top of a compliant system. In particular, we will look at the combination of language features from Grace that require these various extensions, including synchronous APIs, exceptions, and ensuring that 'finally' blocks execute at the appropriate time, as well as demonstrating how easy it is to build concurrent methods for Grace in Hopper. It will also cover the layout of the interpreter and the issue of attempting to support both Node.js and browsers with the same codebase (even in the presence of the browserify tool). Finally, it will consider the challenge of achieving performance in such a setting, where constantly jumping out of execution and deferring to the event loop compounds the more general issue of optimising an interpreter for a dynamic language.
Tim is a PhD student at Victoria University involved in programming language design and type theory. He got his start in open-source and the PL world as a core contributor to the CoffeeScript project before becoming enamoured with Haskell, and now teaches advanced programming language concepts, has produced a few papers in the field, and occasionally writes in Agda. He also organises Pixel Jam, an annual 48-hour game jam in Wellington, during which he always builds novelty fishing simulators.