CSC_52064 - Project - Mini Go

The goal is to build a compiler for a tiny fragment of the Go programming language, called Mini Go, to x86-64 assembly.

All the details are given in the project statement.

The project is due Sunday March 15, 6pm, via Moodle. You must submit an tarball containing

Code supplied

The parser and the abstract syntax are provided. You don't have to read and understand the parser, but you have to read and understand the abstract syntax trees (in ast.mli and tast.mli). They are two kinds of syntax trees:

Roadmap

  1. (labs 4-5) Static Typing

    This is described in section 2.
    Code to be written in typing.ml.
    Test with

    bash ./test -2 path-to-your-compiler
    (see below)

  2. (labs 6-7-8-9) Code Generation

    This is described in section 3.
    Code to be written in compile.ml.
    A module X86_64 is provided, to build and then print x86-64 assembly code.
    Test with

    bash ./test -3 path-to-your-compiler
    (see below)

Test Files

Test files are provided, together with a bash script to test your compiler: Feel free to add more test files of your own (and if so, do include them in the tarball when you submit your project on Moodle).
back to the main page