lunduniversity.lu.se

Computer Science

Faculty of Engineering, LTH

Denna sida på svenska This page in English

Compiler projects fall 2016

EDAN70: Project in Computer Science

Java Code Cleanup using ExtendJ
Hannes Jönsson and Felix Olsson
Abstract:
In order to reduce code size, ensure proper functionality of overridden methods as well as improve clarity of which imports are actually used, a code cleanup tool can be used. This report describes the implementation of such a tool based on the ExtendJ Java compiler. The tool is compared to other tools with similar functionality and its functions are evaluated. The conclusions we draw is that the tool does not produce correct results under all circumstances, a result of the difficulty to ensure coverage of all possible Java functionality.
(paper) (code)

Extending Java with new operators
Hans Bjerndell and Linus Lexfors
Abstract:
We have explored the possibilities of extending the syntax of the Java programming language with a new operator, known as the spread operator, using the extensible Java compiler ExtendJ. The spread operator is a binary operator that accesses a field or calls a method on each object in a collection, a feature we believe to be highly useful. Our extension to ExtendJ consists of new parsing rules, static analysis and a new node type in the abstract syntax tree (AST). Bytecode generation is left as future work, the extension we have developed serves as a basis for further development. In this report we describe the process of developing the extension and provide examples of the spread operator in use. Finally we evaluate the extended compiler, measuring compile-time and comparing the results with the ExtendJ base compiler.
(paper)(code)

Extending Simplic with an LLVM backend
Kasper Bratz and Erik Hedblom
Abstract:
This paper explores the concept of extending an already existing compiler with a back-end for generating LLVM-intermediate code in place of x86-assembler code. A LLVM back-end will be written for an existing compiler for the the language SimpliC, a bare bones implementation of C, to examine what benefits can be made using LLVM. The SimpliC language will also be extended with some new functionality to compare complexity of implementation for x86-assembly and LLVM.
(paper)

LLVM code generation and implementation of nested functions for the SimpliC language
Oscar Legetth and Gustav Svensson
Abstract:
This report will cover our work on the extension of the SimpliC language(a simple C-like language) and its compiler. We will describe SimpliC’s features and the extensions we have made to it. The compiler has been extended with support for LLVM code generation. LLVM code lets us use the different optimization tools that LLVM has. We will then compare the optimized LLVM code with the assembly code that our compiler generated before we started this project in terms of execution time. We will also describe how we implemented the extensions and the LLVM code generation, and the different problems that came along with it.
(paper)