Towards Dream Haskell Build Experience
summary
Mercury builds a Buck2-based Haskell system that achieves module-level incrementality and distributed caching by exposing GHC’s dependency analysis, redesigning interface files, adding first-class bytecode artifacts, unifying compilation modes and shipping a server-mode GHC worker. A 2,000-module codepath sees a 3× wall-time speedup (27→9 minutes); an Amazon comparison shows remote Buck2 on 100 cores drops 60→15 minutes; CI cache hit rate exceeds 90% with 99% of module builds served from cache. Cross-package parallelism cuts some builds by ~50%.
AI-written summary · about
chapters (13)
- 0:00Introduction
- 1:32Scaling Haskell builds
- 4:23Modern build systems at Google and Meta
- 7:37Incremental Haskell builds
- 11:31Haskell rules for Buck2
- 15:03Parallelism in Haskell builds
- 19:24Performance benchmarks
- 21:31GHC integration plans
- 26:05Overhead in one-shot builds
- 27:33GHC server for workers
- 29:39Flexible build targets
- 31:48Migration progress
- 32:54Q&A
related talks
26mBuck2 for OCaml Users & Developers
35mHow we brought down our build times. Modularization impact on build speeds and metrics
53mCompiling like a boss!
49mDRY compiling!
33mTools of the Trade
25mMetro: Scaling JavaScript Build Systems
15mHaskell Playground (WIP)
11mPerformant Bazel Builds for Web Monorepos at Scale
