Code Monkey home page Code Monkey logo

tcc's Introduction

tobante's (crappy) compiler collection

Status

License Linux/macOS Windows Coverage Issues
MIT license Build Status Build status codecov GitHub issues

Features

Everything is in development. See test files for details.

Compiler

Source code is parsed using the Boost Spirit.Qi library. It creates an intermediate representation which generates the assembly.

Virtual Machine

Current implementation is a stack only based virtual machine.

Quick Start

Dependencies

  • C++20
  • CMake 3.12
  • Boost 1.69
    • Filesystem
    • Program Options
    • System
    • Spirit.Qi

Clone

git clone --recursive https://github.com/tobiashienzsch/tcc.git

Build

# unix
CONFIG=Debug make
# same as
CONFIG=Debug make config build test

# visual studio (you may need to edit the boost path in the makefile)
CONFIG=Debug make win
# same as
CONFIG=Debug make config-vs build test

clang-tidy

cd $BUILD_DIR
python ../scripts/run-clang-tidy.py -header-filter="(tcc|tcvm|tcsl)" -quiet -fix -p . ..

Project Structure

$PROJECT_ROOT
  3rd_party     # external code
  benchmark     # benchmarks using google bm
  cmake         # cmake modules
  docs          # documentation
  examples      # files for testing
  playground    # scratchpad
  tcc           # compiler
  tcsl          # shared code
  tcvm          # virtual machine

Resources

tcc's People

Contributors

tobiashienzsch avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.