git404hub

what is incremental-jit fr?

compilers-course-materials/incremental-jit — explained in plain English

Analysis updated 2026-05-18

1RustAudience · researcherComplexity · 5/5Setup · hard

tl;dr

A teaching artifact and paper companion showing how to build a JIT compiler for a small language step by step, with a matching AI reproduction to compare against.

vibe map

mindmap
  root((repo))
    What it does
      Incremental JIT compiler
      Teaches compiler building
    Tech stack
      Rust
      dynasm
      nasm
    Parts
      Section implementations
      Differential test suite
      AI reproduction
    Use cases
      Study compiler construction
      Compare AOT and JIT
    Audience
      Compilers students
      Researchers

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

what do people make with this?

VIBE 1

Study how a JIT compiler is built incrementally, section by section, from numbers up through function calls and optimizations.

VIBE 2

Run the differential test suite to see how ahead of time and just in time compiler backends are checked against each other automatically.

VIBE 3

Compare an AI generated reproduction of the compiler against the original to study how well it followed the paper's specification.

what's the stack?

Rustdynasmnasm

how it stacks up fr

compilers-course-materials/incremental-jitabc3dz/mixxxabyo-software/ferro-stash
Stars111
LanguageRustRustRust
Setup difficultyhardmoderatemoderate
Complexity5/52/54/5
Audienceresearchergeneralops devops

Figures from each repo's GitHub metadata at analysis time.

how do i run it?

Difficulty · hard time til it works · 1h+

Requires a Rust toolchain targeting a specific platform plus the nasm assembler and make, and mainly targets x86_64-apple-darwin.

in plain english

This repository is a teaching artifact that goes with an academic paper about building a just in time, or JIT, compiler step by step. It contains a working compiler, written in Rust, for a small made up programming language called snek, and it is adapted from a real university compilers course at UC San Diego. The point of the project is to show how you can build a compiler incrementally, adding one feature at a time, such as numbers, variables, conditionals, and functions, while keeping two different ways of running the code in agreement with each other the whole way through. The repo is organized into three parts. The first is a series of numbered folders, each one a separate small Rust project representing the compiler exactly as it existed at the end of one section of the paper, starting with basic numbers and ending with JIT specific optimizations. Each of these folders can compile a snek program in two ways: ahead of time into raw assembly code that gets linked and run as a normal program, or just in time, meaning the program is assembled and executed immediately in memory using a technique the code implements with a Rust library called dynasm. The core idea checked throughout is that both approaches must always produce the same result. The second part is a differential test suite, kept in a separate folder called fuzz, which automatically generates many small snek programs, runs each one through both the ahead of time and the just in time backends, and checks that they agree, catching thousands of test cases per run for the more advanced sections. The third part is an independent reproduction attempt, where the AI model Claude Opus was given only the paper's text and asked to rebuild the same compiler from scratch, without seeing the original curated code, so its results could be compared against the official implementation as an experiment in whether an AI can reproduce published research from a paper alone. Running the project requires a Rust toolchain along with the nasm assembler and the make build tool, and it targets a specific processor and operating system combination, though the underlying compiler is not tied to any one platform. The README notes the AI generated reproduction's REPL is not crash safe like the original, since certain invalid inputs make it crash rather than reporting a clean error.

prompts (copy fr)

prompt 1
Walk me through setting up the Rust toolchain, nasm, and make needed to build this incremental JIT compiler.
prompt 2
Explain how the AOT and JIT backends are checked for agreement in this project's differential test suite.
prompt 3
Show me how to build and test one section of the compiler, like 06-conditionals-tags, on its own.
prompt 4
Describe how the Opus reproduction in opus-repro differs from the original curated compiler implementation.

Frequently asked questions

what is incremental-jit fr?

A teaching artifact and paper companion showing how to build a JIT compiler for a small language step by step, with a matching AI reproduction to compare against.

What language is incremental-jit written in?

Mainly Rust. The stack also includes Rust, dynasm, nasm.

How hard is incremental-jit to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is incremental-jit for?

Mainly researcher.

peek the repo → explain another one

This repo across BitVibe Labs

double-check against the repo, no cap.