1Vmgen supports the construction of interpretive systems by generating 2the code for executing and dealing with virtual machine (VM) 3instructions from simple descriptions of the VM instructions. 4 5This file is about Vmgen-specific issues. Issues affecting both 6Gforth and Vmgen (e.g., platform compatibility) are discussed in 7README. 8 9Vmgen generates code for executing VM instructions (with optional 10tracing), for generating VM code, for disassembling VM code, and for 11profiling VM instruction sequences. A VM instruction description 12looks like this: 13 14add ( i1 i2 -- i ) 15i = i1+i2; 16 17Vmgen supports several techniques for writing efficient interpreters: 18virtual machine interpreters, threaded code, combining VM instructions 19into superinstructions, keeping the top-of-stack in a register, 20scheduling the dispatch of the next VM instruction, and a couple of 21minor optimizations. Interpreters created with vmgen usually are 22faster than competing interpreters and are typically only a factor of 232-10 slower than the code generateed by native-code compilers. 24 25Vmgen has special support for stack-based VMs (but it can also be 26used to advantage when implementing a register-based VM). 27 28Changes in Vmgen from earlier releases are explained in NEWS.vmgen. 29 30After installation the documentation is available in info form and in 31printable form (doc/vmgen.ps). 32 33There is a simple usage example in vmgen-ex (and a variation on that 34in vmgen-ex2). See the documentation for more information on that. 35 36To report a bug, use 37<https://savannah.gnu.org/bugs/?func=addbug&group_id=2672>. For 38discussion on Vmgen (e.g., how to use it), use the 39bug-vmgen@mail.freesoftware.fsf.org mailing list (use 40<http://mail.gnu.org/mailman/listinfo/help-vmgen> to subscribe). 41 42You can find vmgen at http://www.complang.tuwien.ac.at/anton/vmgen/. 43 44Vmgen is currently distributed with Gforth (because it needs Gforth to 45run, and Gforth needs it to build), and is installed together with 46Gforth (read INSTALL for instructions). 47 48Note that future versions of vmgen may require small changes in 49programs written for the present version (e.g., requiring a few 50additional macro definitions). 51 52----- 53Copyright (C) 2001, 2002, 2003,2007 Free Software Foundation, Inc. 54 55This file is part of Gforth. 56 57Gforth is free software; you can redistribute it and/or 58modify it under the terms of the GNU General Public License 59as published by the Free Software Foundation, either version 3 60of the License, or (at your option) any later version. 61 62This program is distributed in the hope that it will be useful, 63but WITHOUT ANY WARRANTY; without even the implied warranty of 64MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.#See the 65GNU General Public License for more details. 66 67You should have received a copy of the GNU General Public License 68along with this program. If not, see http://www.gnu.org/licenses/. 69