EarlGray / language-incubator

Learning compilers, interpreters, code generation, virtual machines, assemblers, JITs, etc.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

language-incubator

An incubator/sandbox for learning compilers, interpreters, code generation, virtual machines, assemblers, JITs, etc.

Hacks that have grown into separate projects:

  • x86/hasm: a simple x86 assembler written in Haskell, for now it's opcode set is very limited;
  • fp/secd: implementation of SECD virtual machine in C with a Scheme-to-SECD compiler;

Some protoprojects that may be interesting:

  • js/slothjs: an effort at a naïve, primitive, savage Javascript interpreter (with parsing offloaded to Esprima);
  • bf/bfjc: a primitive but fully functional x86_64 JIT compiler for BrainFuck, inspired by Adventures in JIT compilation by eliben ;
  • fp/tapl: reimplementation of some typecheckers from TAPL (in Haskell/Prolog), e.g. fullsimple.
  • llvm/kldscp: LLVM tutorial, JIT compiler of a toy language Kaleidoscope;
  • forth/mips/mforth.S: rewrite of the awesome jonesforth from x86/Linux to MIPS/Linux (tested on CI20);
  • c/longjmp/x86: a hackish reimplementation of setjmp/longjmp compliant to GCC x86 ABI;
  • zoo/{calc, miniml, minihs, miniprolog, boa}: a mirror of the awesome PLZoo ;
  • rel/chr: small Constraint Handling Rules examples;

About

Learning compilers, interpreters, code generation, virtual machines, assemblers, JITs, etc.

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Rust 43.4%Language:Haskell 15.3%Language:C 10.1%Language:OCaml 7.6%Language:Assembly 5.0%Language:Prolog 4.3%Language:C++ 3.4%Language:Brainfuck 2.4%Language:JavaScript 1.7%Language:Python 1.2%Language:Scheme 0.8%Language:Ruby 0.7%Language:HyPhy 0.7%Language:Yacc 0.7%Language:Isabelle 0.5%Language:SMT 0.4%Language:Makefile 0.4%Language:Idris 0.4%Language:Lex 0.3%Language:Forth 0.2%Language:HTML 0.1%Language:CSS 0.1%Language:Erlang 0.1%Language:Shell 0.1%Language:CMake 0.1%Language:LLVM 0.0%Language:Pascal 0.0%