Skip to content

spodym/Jacaranda

Repository files navigation

Jacaranda - Latte compiler

Project for Compiler Construction class at University of Warsaw.

I. First iteration of project:
1. Building tree:
    AST (Abstract syntax tree) for Latte program is build using ANTLRv3.
    Latte grammar is defined in: mrjp.latte.generator/src/latte/grammar/latte.g

2. Syntax & semantics analyss:
    Syntax analyss is performed by ANTLR during AST loading.
    Semantics analyss is placed in function:
        void checkType(CommonTree root)
    Placed in TreeBuilder.java
    It performs function types checking, types checking & return statements
    checking.

II. Second iteration of project:
1. Compiler for JVM

III. Third iteration of project:

1. Compiler for x86

2. Optimizations
    - calculating exact space in frame for variables

3. Addons
    - arrays

How to run?
$ make
$ # compiling to JVM
$ ./latte_jvm.sh path_to_latte_file.lat
$ # compiling to x86
$ ./latte_x86.sh path_to_latte_file.lat

http://www.mimuw.edu.pl/~ben/Zajecia/Mrj2011/Latte/ - project site
http://en.wikipedia.org/wiki/Jacaranda - random name for project

About

MRJP task - Latte compiler

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published