awesome-repositories.com
Blog
MCP
awesome-repositories.com

Discover the best open-source repositories with AI-powered search.

ExploreCurated searchesOpen-source alternativesSelf-hosted softwareBlogSitemap
ProjectMCP serverAboutHow we rankPress
LegalPrivacyTerms
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
rswier avatar

rswier/c4

0
View on GitHub↗

C4

c4 is a minimalist C compiler and programming tool designed to translate C source code into executable machine code using a small set of functions. It functions as a stripped-down compilation utility focused on a tiny codebase.

The project serves as an educational tool for studying the internal mechanics of the compilation process. It implements minimalist C compilation to demonstrate how source files are transformed into low-level binary executables.

The compiler utilizes a single-pass compilation model with recursive descent parsing and direct-to-binary emission. It manages the translation process through a minimalist symbol table, hard-coded instruction mapping, and stack-based value passing.

AI search

Explore more awesome repositories

Describe what you need in plain English — the AI ranks thousands of curated open-source projects by relevance.

Start searching with AI

Features

  • C Source Translators - Provides a minimalist compiler that translates C source files directly into machine-specific executable instructions.
  • Educational Compilers - Serves as an educational tool for studying the internal mechanics of compilation via a simplified C compiler.
  • Recursive Descent Parsers - Employs recursive descent parsing to analyze nested language structures through mutually recursive functions.
  • Symbol Table Managers - Implements a minimalist symbol table to resolve memory addresses for variables and functions during compilation.
  • Opcode Mappings - Utilizes a hard-coded instruction mapping table to translate C constructs into machine opcodes.
  • Stack-Based Value Passing - Manages local variables and function arguments by pushing and popping values from the hardware call stack.
  • Minimalist Toolchains - Features a stripped-down codebase and a limited set of functions to illustrate essential compilation mechanics.
  • Direct-to-Binary Emission - Implements a direct-to-binary emission process that bypasses the need for a separate assembler.
  • Minimalist Implementations - Implements a stripped-down compilation process to demonstrate how C source is transformed into binaries.
  • Single-Pass Compilers - Uses a single-pass compilation model to transform source code into machine code in one traversal.
  • C Programming Tools - Provides a low-level utility for compiling C language source files into binary executables.
  • C Tooling - Functions as a low-level programming tool for processing C source files into binary executables.
  • Compilers and Interpreters - C language implementation in four functions.
10,726 stars·1,495 forks·C·GPL-2.0·13 views

Star history

Star history chart for rswier/c4Star history chart for rswier/c4

How this analysis was created: This summary and feature list are AI-generated from collected project material and can contain mistakes. Stars, license and language are imported from GitHub. Inclusion does not mean that we have tested or audited this project. Check the source documentation for any feature you depend on. Learn more on our About page.

Frequently asked questions

What does rswier/c4 do?

c4 is a minimalist C compiler and programming tool designed to translate C source code into executable machine code using a small set of functions. It functions as a stripped-down compilation utility focused on a tiny codebase.

What are the main features of rswier/c4?

The main features of rswier/c4 are: C Source Translators, Educational Compilers, Recursive Descent Parsers, Symbol Table Managers, Opcode Mappings, Stack-Based Value Passing, Minimalist Toolchains, Direct-to-Binary Emission.

Which projects share features with rswier/c4?

Projects with overlapping indexed features include: thejameskyle/the-super-tiny-compiler — This project is an educational compiler implementation and a minimalist compiler construction tutorial. It serves as a… jamiebuilds/the-super-tiny-compiler — This project is an educational compiler implementation and architecture demo. It serves as a small-scale C-style… rui314/chibicc — Chibicc is a C11 compiler designed as a reference implementation for studying compiler construction. It translates C… alecthomas/participle — Participle is a Go parser generator and toolkit for building language frontends. It provides a declarative grammar… zig-lang/zig — Zig is a low-level systems programming language designed for writing high-performance software that interacts directly… anthropics/claudes-c-compiler — Claudes C Compiler is a self-contained C compiler toolchain that parses source code, optimizes intermediate…

Projects sharing features with C4

These projects share indexed features with C4. Shared tags can include platform or build tooling; verify the primary use case before treating a result as a replacement.
  • thejameskyle/the-super-tiny-compilerthejameskyle avatar

    thejameskyle/the-super-tiny-compiler

    28,527View on GitHub↗

    This project is an educational compiler implementation and a minimalist compiler construction tutorial. It serves as a practical example of how to build a functional compiler through a simplified end-to-end development process, transforming source code into executable instructions. The implementation is designed to teach the fundamentals of language implementation and compiler design. It focuses on the essential mechanics of transforming source code by demonstrating the core architecture of a translation process. The system covers the primary stages of compilation, including lexical analysis

    JavaScript
    View on GitHub↗28,527
  • jamiebuilds/the-super-tiny-compilerjamiebuilds avatar

    jamiebuilds/the-super-tiny-compiler

    28,525View on GitHub↗

    This project is an educational compiler implementation and architecture demo. It serves as a small-scale C-style language compiler designed to demonstrate the fundamental stages of transforming source code into executable machine instructions. The codebase functions as a tool for compiler architecture education and design prototyping. It illustrates the process of building an educational language implementation to help users understand the mechanics of parsing and code generation. The implementation covers the primary stages of a compiler pipeline, including regular expression tokenization,

    JavaScript
    View on GitHub↗28,525
  • rui314/chibiccrui314 avatar

    rui314/chibicc

    11,694View on GitHub↗

    Chibicc is a C11 compiler designed as a reference implementation for studying compiler construction. It translates C source code into machine-specific assembly instructions by utilizing a pipeline that includes lexical analysis, recursive descent parsing, and single-pass code generation. The project serves as an educational tool for understanding the internal architecture of compilers, from initial tokenization to the final emission of machine code. The compiler distinguishes itself through its self-hosting capability, which allows the software to compile its own source code into a functional

    C
    View on GitHub↗11,694
  • alecthomas/participlealecthomas avatar

    alecthomas/participle

    3,869View on GitHub↗

    Participle is a Go parser generator and toolkit for building language frontends. It provides a declarative grammar framework that uses reflection and struct tags to map input patterns directly into typed data structures. The library features a stateful lexical analyzer that employs state machines to handle nested or modal patterns. It includes a lexer code generator to produce optimized code, reducing runtime memory allocations and increasing throughput. The project covers recursive descent parsing with support for union types via sealed interfaces and custom parsing logic through interface-

    Goastebnfgo
    View on GitHub↗3,869
Compare all 30 related projects→