Awesome Compilers

Background, Books

68 resources on creating programming languages

A Compiler Writing Journey

An Incremental Approach to Compiler Construction: Scheme and Functional Programming 2006; Abdulaziz Ghuloum -- Github Step-by-step development of a Scheme-to-x86 compiler

An Introduction to GCC - Brian Gough

Basics of Compiler Design (Anniversary Edition) - Torben Mogensen

Compiler Design in C (1990) - Allen Holub, Prentice Hall

Compiler Design: Theory, Tools, and Examples - Seth D. Bergmann

Computer Language Notes: Compilers and Interpreters

Compiling Scala for the Java Virtual Machine - Michel Schinz (PDF)

Compiling Techniques (1969) - F.R.A. Hopgood, Macdonald

Essentials of Compilation: An Incremental Approach by Siek, Newton: A book about compiling Racket to x86-64 assembly

Essentials of Programming Languages: EOPL, as it’s better known, introduces readers to the internal workings of programming languages by describing small programming languages and creating an interpreter for each one. The book is very hands-on, with lots of exercises for the reader to modify the interpreters with new features. It touches on the ideas of reasoning about languages and formal semantics, but mostly sticks to the interpreter-as-semantics approach.

How to Design Programs

Implementing Functional Languages: A Tutorial - Simon Peyton Jones, David Lester

Introduction to Compilers and Language Design | Introduction to Compilers and Language Design - Douglas Thain (PDF)

Let's Build a Compiler (PDF)

Practical and Theoretical Aspects of Compiler Construction (class lectures and slides)

Programming Language Pragmatics by Michael L Scott. Covers theoretical background behind languages beyond syntax.

Programming Languages: Application and Interpretation (http://cs.brown.edu/courses/cs173/2012/book/)

Programming languages and techniques (PDF)

Resources for Amateur Compiler Writers

Semantics Engineering with PLT Redex: The PhD-level programming languages course at Northeastern uses the Redex book, and I found it to be a good introduction. The tool itself (Redex) is a great way to experiment with semantics, including reduction relations (roughly, the part of the semantics that says how the program runs) and type systems. You could use this book as a substitute for TAPL (at least for learning the basics of formal semantics), or you could use Redex to experiment with the languages described in TAPL.

mpri-2.4-public: Resources for course MPRI 2-4 on functional programming and type systems.

"Bits of History, Words of Advice": The creator of Newspeak and one of the core developers working on Java and the JVM offers some advice about Smalltalk's lack of success in the mainstream.

Lists of recommended reading

GCC Wiki - List of compiler books

Jordan Rose (Swift team) recommendations

http://jschuster.org/blog/2016/11/29/getting-started-in-programming-languages/

Jonathan Turner’s Reading List: Turner is an engineer on Mozilla’s Rust team and recently posted his reading list for getting up-to-speed on programming languages. The list starts with some resources on how to build interpreters and compilers, but also points to more academic material later.

10PL: This is a list compiled by Northeastern’s PL faculty of (roughly) ten academic papers that they think every student in PL should know. Not all of them are PL papers themselves, and they don’t form a full foundation on their own, but they form a kind of “great books” list for PL.

Benjamin Pierce, the author of TAPL, also has a similar list (although with a slightly more type-heavy and theoretical bent).

Classic Papers in Programming Languages and Logic by Karl Crary

Tutorials/Intros/Walkthroughs

FreeCompilerCamp.org: Online Training for Extending Compilers Github:
- Clang/LLVM Tutorials
- http://freecompilercamp.org/clang-llvm-landing
- Alok Mishra, Anjia Wang, Chunhua Liao, Yonghong Yan, Barbara Chapman
- https://sc19.supercomputing.org/proceedings/tech_poster/tech_poster_pages/rpost138.html
- FreeCompilerCamp.org: Training for OpenMP Compiler Development from Cloud
- https://sc19.supercomputing.org/proceedings/workshops/workshop_pages/ws_bphpcte103.html

Creating the Bolt Compiler (series):

Let's Build an Interpreter (series) (Github):

Immo Landwerth has done a collection of videos on building a language called Minsk, for the CLR platform, in a live-streaming style: Source:
* Episode 1
* Episode 2
* Episode 3
* Episode 4
* Episode 5
* Episode 6
* Episode 7
* Episode 8
* Episode 9
* Episode 10
* Episode 11
* Episode 12
* Episode 13
* Episode 14
* Episode 15
* Episode 16
* Episode 17
* Episode 18
* Episode 19
* ... more are likely on the way

College/University Courses

Functional programming and type systems; supplemental repo

Stanford OpenEdX: Compilers - Alex Aiken

Brown CS: CSCI 1730: Programming Languages Videos

OPLSS (Oregon Programming Languages Summer School)
- 2019-2017, 2003: https://www.youtube.com/channel/UCDe6N9R7U-RYWA57wzJQ2SQ/playlists
- 2016-2015: https://www.youtube.com/channel/UCsON_8vogp4nCQFTnfu43kA/playlists
- free video lectures available, including the introductory ones based on Practical Foundations for Programming Languages: http://www.cs.cmu.edu/~rwh/pfpl/

Principles of Programming Languages

Programming Language Implementation Summer School (PLISS) YouTube

University of Utah: Advanced Compilers - John Regehr
- Weeks 1 and 2: http://blog.regehr.org/archives/1419
- Weeks 3-5: http://blog.regehr.org/archives/1428

UW professor Dan Grossman's teaching materials

UW CSE CSEP 501: Compilers - Hal Perkins
- Winter 2018
- Homepage: https://courses.cs.washington.edu/courses/csep501/18sp/
- Lecture Videos: https://courses.cs.washington.edu/courses/csep501/18sp/video/
- Winter 2016
- Homepage: https://courses.cs.washington.edu/courses/csep501/16wi/
- Playlist: https://www.youtube.com/playlist?list=PLTPQEx-31JXhfAWGnGzwbfhB2zUB7Jd4C
- Topics: https://courses.cs.washington.edu/courses/csep501/16wi/calendar/lecturelist.html

SFU CMPT 886: Program Analysis and Reliability - Nick Sumner, Spring 2015 YouTube playlist

UCSD CSE 131: Compiler Construction
- Fall 2019; Joseph Gibbs Politz
- https://ucsd-cse131-f19.github.io/
- https://podcast.ucsd.edu/watch/fa19/cse131_a00
- Winter 2018; Ranjit Jhala
- https://ucsd-progsys.github.io/131-web/
- https://podcast.ucsd.edu/watch/wi18/cse131_a00

UCSD CSE 231: Advanced Compiler Design
- Winter 2019; Sorin Lerner
- https://podcast.ucsd.edu/watch/wi19/cse231_a00
- https://ucsd-pl.github.io/cse231/wi19/

NPTEL: Compiler Design (YouTube playlist): 2011; Y.N. Srikant


Detection

Pre-defined Compiler Macros - https://sourceforge.net/p/predef/wiki/
- Architectures - https://sourceforge.net/p/predef/wiki/Architectures/
- Compilers - https://sourceforge.net/p/predef/wiki/Compilers/
- Endianness - https://sourceforge.net/p/predef/wiki/Endianness/
- Language Standards - https://sourceforge.net/p/predef/wiki/Standards/
- Operating Systems - https://sourceforge.net/p/predef/wiki/OperatingSystems/
- Standard Libraries - https://sourceforge.net/p/predef/wiki/Libraries/

SPY: Friendly Neighborhood C++17 Constexpr Predef Wrapper
- OS, compiler, libc, stdlib detection
- https://github.com/jfalcou/spy


Conferences

Compilers Call For Papers for Conferences, Workshops and Journals at WikiCFP - http://www.wikicfp.com/cfp/call?conference=compilers

Computer Architecture and Compilers Conference Map - http://archconfmap.com/

Documentation

Sanitizers

Talks

2019

2018

2017

2016

2015

2014

2013


Tags: reading   langdev   computer science   list  

Last modified 19 December 2022