Project : vasy
The TRAIAN Compiler
We develop a compiler named Traian for translating descriptions written in the Lotos NT language (see § 2.3) into C programs, which will be used for simulation, rapid prototyping, verification, and testing.
The current version of Traian performs lexical analysis, syntactic analysis, abstract syntax tree construction, static semantics analysis, and C code generation for Lotos NT types and functions.
Although this version of Traian is still incomplete (it does not handle Lotos NT processes), it already found useful applications in compiler construction . The recent compilers developed by the Vasy team — namely Aal (see § 6.1.5), Evaluator 4.0 (see § 6.1.4), Exp.Open 2.0 (see § 6.1.7), Ntif (see § 6.2.3), and Svl (see § 6.1.9) — all contain a large amount of Lotos NT code, which is then translated into C code by Traian. Our approach consists in using the Syntax tool (developed at Inria Rocquencourt) for lexical and syntactic analysis together with Lotos NT for semantical aspects, in particular the definition, construction, and traversals of abstract trees. Some involved parts of the compiler can also be written directly in C if necessary. The combined use of the Syntax, Lotos NT, and Traian proves to be satisfactory, as regards both the rapidity of development and the quality of resulting compilers.
The Traian compiler can be freely downloaded from the Vasy Web site (see http://www.inrialpes.fr/vasy/traian).