Last update: 14th May 2017

Papers, Teaching, Biography, Contact, Links


Laurence E. Day


If you're looking for my current whereabouts, I'm employed at Standard Chartered as a Haskell developer in Singapore.
If you're looking to get in touch, you can contact me at laurence dot e dot day at outlook dot com rather than via Nottingham channels.

Otherwise...

I'm an escaped PhD student from the Functional Programming Laboratory of the School of Computer Science at the University of Nottingham, where I was supervised by Professor Graham Hutton. I'm predominantly a Haskell programmer, but also meddle with C#, Python, JavaScript, Standard ML and OCaml.

My PhD research investigated the possibilities of using monads as an aid to constructing modular compilers within a functional framework, building upon previous work in the field on modular interpreters. I'm also interested in multicore/heterogeneous computing, automatic parallelisation, provably correct code transformations, category theory and automated theorem proving within functional languages.

On the 16th of December 2014 I submitted my doctoral thesis, entitled `The Modular Compilation of Effects'. On the 13th of March 2015 I passed with minor corrections, and on the 23rd of October 2015 my corrections were accepted. I'll be officially graduating (after multiple deferrals) on the 18th of July 2017.


Papers

The Modular Compilation of Effects (PhD Thesis, 2015)

Final version, pending submission to etheses.nottingham.ac.uk. Uploaded 14th May 2017.

Native Offload of Haskell Repa Programs to Integrated GPUs (with Hai Liu, Neal Glew, Todd A. Anderson and Rajkishore Barik, FHPC 2014)

In light of recent hardware advances, General Purpose Graphics Processing Units (GPGPUs) are becoming increasingly commonplace, and demand novel programming models to account for their radically different architecture. For the most part, existing approaches to programming GPGPUs within a high-level programming language choose to embed a domain specific language (DSL) within a host metalanguage and implement a compiler mapping programs written within said DSL to code in low-level languages such as OpenCL and CUDA. We question this design choice, and argue that by directly implementing a GPGPU offload primitive as part of a general-purpose language compiler, we gain access to a substantial number of existing optimisations without having to reimplement them in a DSL compiler. In this paper we describe the structure of our prototypical treatment of this research direction, demonstrating the applicability of our approach by showing how to bridge between APIs by extending the Repa library of Haskell with an offload primitive, and detailing an experimental implementation of our approach within the Intel Labs Haskell Research Compiler (HRC). We also provide a detailed study of a set of nine benchmarks, by compiling them to both GPU and two distinct CPUs and comparing their performance.

Pick'n'Fix: Capturing Control Flow in Modular Compilers (with Patrick Bahr, TFP 2014)

We present a modular framework for implementing languages with effects and control structures such as loops and conditionals. This framework enables modular definitions of both syntax and semantics as well as modular implementations of compilers and virtual machines. In order to compile control structures, in particular cyclic ones, we employ Oliveira and Cook's purely functional representation of graphs. Moreover, to separate control flow features semantically from other language features, we represent source languages using Johann and Ghani's encoding of generalised algebraic datatypes as fixpoints of higher-order functors. We demonstrate the usage of our modular compiler framework with two running examples and highlight the extensibility of our modular semantic definitions and compiler implementations.

Compilation À La Carte (with Graham Hutton, IFL 2013)

In previous work, we proposed a new approach to the problem of implementing compilers in a modular manner, by combining earlier work on the development of modular interpreters using monad transformers with the a la carte approach to modular syntax. In this article, we refine and extend our existing framework in a number of directions. In particular, we show how generalised algebraic datatypes can be used to support a more modular approach to typing individual language features, we increase the expressive power of the framework by considering mutable state, variable binding, and the issue of noncommutative effects, and we show how the Zinc Abstract Machine can be adapted to provide a modular universal target machine for our modular interpreters.

Programming Macro Tree Transducers (with Patrick Bahr, WGP 2013)

Tree transducers are tree automata defining functions from trees to trees. Put simply, a tree transducer is a set of mutually recursive functions transforming an input tree into an output tree. Macro tree transducers extend this recursion scheme by allowing each function to be defined in terms of an arbitrary number of accumulation parameters. In this paper, we show how macro tree transducers can be concisely represented in Haskell, and demonstrate the benefits of using such an approach with a number of examples. In particular, tree transducers afford a modular programming style as thy can be easily composed and manipulated. Our Haskell representation generalises the original definition of (macro) tree transducers, abolishing a restriction on finite state spaces. However, as we demonstrate, this generalisation does not affect compositionality.

Towards Modular Compilers For Effects (with Graham Hutton, TFP 2011) [winner: Best Paper Award]

Compilers are traditionally factorised into a number of separate phases, such as parsing, type checking, code generation, etc. However, there is another potential factorisation that has received comparatively little attention: the treatment of separate language features, such as mutable state, input/output, exceptions, concurrency, etc. In this article we focus on the problem of modular compilation, where the aim is to develop compilers for separate language features and prove their correctness independently, which can then be combined as required. We summarise our progress so far, issues that have arisen, and further work.


Teaching

During my PhD, I was fairly ubiquitous when it came to tutoring first and second year modules, generally on the theoretical side of things. I love teaching, and so I'm honoured to have been presented with the University-wide "Best Postgraduate That Teaches" award by the Students' Union in 2013.

Teaching Assistant

Spring Semester

G51FUN Functional Programming ['12-'13] ['11-'12] ['10-'11], ['09-'10]

G52AFP Advanced Functional Programming ['12-'13] ['11-'12] ['10-11]

G52MAL Machines and their Languages ['12-'13] ['11-'12] ['10-'11]

Autumn Semester

G51MCS Mathematics for Computer Scientists ['12-'13] ['11-'12] ['10-'11]

G51APS Algorithmic Problem Solving ['12-'13] ['11-'12]

G53CMP Compilers ['12-'13] ['11-'12]


Contact

A note to recruiters: I am not currently in the market for employment, as I am happily engaged at Standard Chartered as a process automation and efficiency engineer.
However, interesting offers always make for intriguing reading, as I am looking to take up a position as a quantitative Haskell developer in the UK at some point in the future.

IRL: Floor 6, Standard Chartered @ Changi Business Park, Singapore 455939

Facebook: Laurence E. Day - I keep this account public to all, but opinions are obviously my own, and only a fool would take anything posted there as fact.

Twitter: @dizzeehaskell


Links

Functional Programming Laboratory

School of Computer Science, University of Nottingham