Past Meetup

Type-directed compilation in the wild: Haskell and Core

This Meetup is past

87 people went

Location image of event venue


Speaker: Simon Peyton Jones.

Academic papers often describe typed calculi, but it is rare to find one in a production compiler. Indeed, the Glasgow Haskell Compiler (GHC) may be the only production compiler in the world that really has a remorselessly statically-typed intermediate language, informally called "Core", or (when writing academic papers) the more respectable-sounding "System FC".

As real compilers go, GHC's Core language is tiny: it is a slight extension of System F, with letrec, data types, and case expressions. Yet all of Haskell (now a bit of a monster) gets translated into it. In the last few years we have added one new feature to Core, namely typed (but erasable) coercions that witness type equalities, which turn Core into a particular kind of proof-carrying code. This single addition has opened the door to a range of source-language extensions, such as GADTs and type families.

In this talk Simon will describe Core, and how it has affected GHC's development over the last two decades, concentrating particularly on recent developments, coercions, evidence, and type families.

To test your mettle Simon hopes to end up with the problem they are currently wrestling with: proving consistency of a non-terminating rewrite system with non-left-linear rules.