TonicVMTonicVM (To .NET Intermediate Code Virtual Machine) is an experimental software tool from InnoveWare Solutions.
TonicVM is designed to create automatic ports of programs written in a particular language to any Web platform.
TonicVM may be useful to port legacy applications but also modern applications to any browser.
How does TonicVM work?TonicVM is both a source-to-source compiler and a virtual machine.
The compiler supports a number of languages to be compiled using a program (called a front-end).
Each front-end is made of a lexer and a parser. For some languages, a preprocessor is also required (C or C++ languages for example).
The lexer extracts tokens from the language and the parser creates an abstract syntax tree (AST) representation of the source code.
The syntax tree is translated into common intermediate code (the target language) using another program (called a back-end).
Each back-end is made of a code optimizer and a code generator.
The code optimizer applies transformations to the syntax tree and the code generator outputs the target source code from it.
To run the final translated code on the Web platform, a virtual machine is used.
This virtual machine is designed to support all features of the source language (the emulation layer) and its host operating system (the host system).