next up previous contents index
Next: 8.1 Java Code Design Up: DCHARTS, A FORMALISM FOR Previous: 7.4 Limitation and Future   Contents   Index


8. SCC - A DCHARTS COMPILER

SCC (StateChart Compiler) is a command-line tool to synthesize executable code from DCharts models. It optimizes the models and produces efficient code. The code is independent of the SVM simulator.

SCC is able to synthesize code in Java, C++, C# and Python. Those target languages can be chosen on the command-line when the user invokes SCC.

SCC is distributed with SVM. It is started with the scc script (or scc.bat for DOS). A command-line parameter specifies the .des file name of a model description. The code is written to a file with the same name as the model description (with its extension changed according to the target language).

This chapter mainly discusses code synthesis in Java. Several classes are defined in a single Java source file, so when it is compiled with JDK (Java Development Kit), multiple .class files are produced. The class with the same name as the Java source file and the model description is the main public class. A main function is defined in this class, which provides the default textual interface.

More information about SCC can be found at its homepage:

http://msdl.cs.mcgill.ca/people/tfeng/?research=scc

Usage and several examples on SCC can be found in the SVM and SCC Tutorial [39].



Subsections
next up previous contents index
Next: 8.1 Java Code Design Up: DCHARTS, A FORMALISM FOR Previous: 7.4 Limitation and Future   Contents   Index
Thomas Huining Feng 2004-04-28