Skip to main content
University of Glasgow
A-Z : ACADEMIC DEPARTMENTS | SERVICES | STAFF |
Faculty of Information and Mathematical Systems > Department of Computing Science

Languages and Machines

Page 1/1: 1

2009-08-04

Ruby to SystemC Translator

The reference implementation of the Gannet Platform is written in Ruby. The choice of Ruby as a system-level prototyping language might seem odd, but its advantages are that it is clear and easy to learn, with a simple but powerfull object model.

The reference model is the specification for the Gannet Platform, and as a specification language Ruby has proven an excellent choice. By restricting the coding style to non-idiomatic and adding type annotations in comments, it was possible to translate the Ruby code to C++ and from there to SystemC, the de facto standard for system-level modelling, using a relatively straightforward translator written in Perl.

The very fact that it is possible to translate Ruby to C++ is of course the key justification for the choice. The current translator is far from perfect, and translation to SystemC will never be completely automatic. However, the system is already powerfull enough to create the expression component of the Gannet SystemC model (i.e. the actual implementation of all methods) from the Ruby specification. The coordination component (ports, exports) has to be created manually, but as this part of the code does not change often, the productivity gain is still considerable.

The translator is part of the Gannet source code, www.gannetcode.org.

2009-08-03

First Release of the Gannet SoC Platform

The source code and documentation for the alpha release of the Gannet System-on-Chip Platform is now available on the Gannet project web site. The release includes a compiler for the Gannet language (written in Haskell), a reference implementation of the platform in Ruby, a C++ Virtual Machine and a SystemC system-level model of the hardware platform.

powered by Blosxom