Skip to content

cderici/around-the-world-in-compilers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

132 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Around the World in Compilers

C++23 LLVM 20

This is a collection of small experimental languages and compilers, one for every letter of the alphabet, each named after a world city. Here I explore the world of compilation, language design, compiler optimizations, and all the cool stuff around compiler technologies.

Some of these work on the frontend (e.g. MLIR.smt + Z3 based verification), but most should focus on the backend (LLVM instruction selection and later passes), my interests generally lean towards the backend.

They share pieces of compiler infrastructure whenever possible (e.g. lexing/parsing). Some target LLVM IR, some target PTX for CUDA experiments, some target MLIR, and some include a repl (e.g. Athens has an LLVM ORC-based JITted repl).

It's my personal lab to explore ideas in language design and implementation, IR construction, optimization behavior, and runtime. It's an open-ended playground, so it will probably never be fully complete.


There's no semantic relation between the cities and the languages, it's just fun naming.


Languages Concept / Focus Based On Status
Athens Enhanced Kaleidoscope-style language targeting LLVM IR, with an LLVM ORC JIT repl. -- Athens CI
Berlin Produces MLIR in affine/linalg dialects for polyhedral analysis. Enables loop tiling, fusion, interchange, and dependence analysis before final lowering. Athens Berlin CI
Cairo This is basically Athens with LLVM IR targeting nvptx64-nvidia-cuda, producing PTX kernels via NVIDIA GPU codegen. Has an option to launch them via the CUDA driver API. Athens Cairo CI
Dublin MLIR based verification playground. Takes a small func/arith/cf.assert fragment, uses the smt dialect for the assertion fail query, emits SMT LIB (.smt2), runs Z3, and reports verified or counterexample. Currently just straight line bitvector arithmetic, then we'll grow into control flow, loops, affine/linalg, shapes, etc. Berlin / Athens Dublin CI
Edinburgh LLVM MIR scheduling playground. Implements custom MachineScheduler strategies that choose from LLVM's ready set using critical path, latency hiding, and register pressure heuristics, then compares the resulting MIR against LLVM's default scheduler. Athens / Cairo Edinburgh CI
Florence A shot at architecture-aware design for large-scale systems. Trying to make architectural considerations explicit and enforcable: first-class modules, boundaries, layers, dependency directions, etc, for clean separation, stable interfaces, and explicit/intentional (de-)coupling. -- 🚧
Geneva Uses Tapir/LLVM + Cilk (Plus) runtime system to explore paralellism (e.g. loop parallelism via cilk_for). Compares LLVM IR structure and performance against Berlin in various architectures. -- 🚧
Havana
Istanbul
Jakarta
Kyoto
Lisbon
Montreal
Nairobi
Oslo
Prague
Quito
Reykjavík
Seoul
Tallinn
Utrecht
Vienna
Warsaw
Xanthus
Yerevan
Zürich

About

A lab of experimental compilers and languages playing around LLVM, MLIR, CUDA, PTX, x86_64, etc.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors