123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239 |
- <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html401/loose.dtd">
- <html>
- <!-- Created on November 8, 2012 by texi2html 1.82
- texi2html was written by:
- Lionel Cons <[email protected]> (original author)
- Karl Berry <[email protected]>
- Olaf Bachmann <[email protected]>
- and many others.
- Maintained by: Many creative people.
- Send bugs and suggestions to <[email protected]>
- -->
- <head>
- <title>avram - a virtual machine code interpreter: Preface</title>
- <meta name="description" content="avram - a virtual machine code interpreter: Preface">
- <meta name="keywords" content="avram - a virtual machine code interpreter: Preface">
- <meta name="resource-type" content="document">
- <meta name="distribution" content="global">
- <meta name="Generator" content="texi2html 1.82">
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- <style type="text/css">
- <!--
- a.summary-letter {text-decoration: none}
- blockquote.smallquotation {font-size: smaller}
- pre.display {font-family: serif}
- pre.format {font-family: serif}
- pre.menu-comment {font-family: serif}
- pre.menu-preformatted {font-family: serif}
- pre.smalldisplay {font-family: serif; font-size: smaller}
- pre.smallexample {font-size: smaller}
- pre.smallformat {font-family: serif; font-size: smaller}
- pre.smalllisp {font-size: smaller}
- span.roman {font-family:serif; font-weight:normal;}
- span.sansserif {font-family:sans-serif; font-weight:normal;}
- ul.toc {list-style: none}
- -->
- </style>
- </head>
- <body lang="en" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
- <a name="Preface"></a>
- <table cellpadding="1" cellspacing="1" border="0">
- <tr><td valign="middle" align="left">[<a href="avram.html#Top" title="Previous section in reading order"> < </a>]</td>
- <td valign="middle" align="left">[<a href="User-Manual.html#User-Manual" title="Next section in reading order"> > </a>]</td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left">[ << ]</td>
- <td valign="middle" align="left">[<a href="avram.html#Top" title="Up section"> Up </a>]</td>
- <td valign="middle" align="left">[<a href="User-Manual.html#User-Manual" title="Next chapter"> >> </a>]</td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left">[<a href="avram.html#Top" title="Cover (top) of document">Top</a>]</td>
- <td valign="middle" align="left">[<a href="avram_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
- <td valign="middle" align="left">[<a href="Function-Index.html#Function-Index" title="Index">Index</a>]</td>
- <td valign="middle" align="left">[<a href="avram_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
- </tr></table>
- <hr size="1">
- <a name="Preface-1"></a>
- <h1 class="unnumbered">Preface</h1>
- <p><code>avram</code> is a virtual machine code interpreter. It reads an input
- file containing a user-supplied application expressed in virtual machine
- code, and executes it on the host machine. The name is a quasi-acronym
- for “Applicative ViRtuAl Machine”. Notable features are
- </p>
- <a name="index-functional-programming"></a>
- <a name="index-environment"></a>
- <a name="index-Unix"></a>
- <ul>
- <li> strong
- support for functional programming operations (e.g., list processing)
- </li><li>
- interfaces to selected functions from mathematical libraries, such as
- <ul>
- <li>
- <code>gsl</code> (numerical integration, differentiation, and series acceleration)
- <p><a href="http://www.gnu.org/software/gsl/">http://www.gnu.org/software/gsl/</a>
- </p></li><li>
- <code>mpfr</code> (arbitrary precision arithmetic)
- <p><a href="http://www.mpfr.org">http://www.mpfr.org</a>
- </p></li><li>
- <code>minpack</code> (non-linear optimization)
- <p><a href="http://www.netlib.org/minpack">http://www.netlib.org/minpack</a>
- </p></li><li>
- <code>lapack</code> (linear algebra)
- <p><a href="http://www.netlib.org/lapack">http://www.netlib.org/lapack</a>
- </p></li><li>
- <code>fftw</code> (fast fourier transforms)
- <p><a href="http://www.fftw.org">http://www.fftw.org</a>
- </p></li><li>
- <code>Rmath</code> (statistical and transcendental functions)
- <p><a href="http://www.r-project.org">http://www.r-project.org</a>
- </p></li><li>
- <code>ufsparse</code> (sparse matrices)
- <p><a href="http://www.cise.ufl.edu/research/sparse/SuiteSparse/current/SuiteSparse/">http://www.cise.ufl.edu/research/sparse/SuiteSparse/current/SuiteSparse/</a>
- </p></li><li>
- <code>glpk</code> (linear programming by the simplex method)
- <p><a href="http://www.gnu.org/software/glpk">http://www.gnu.org/software/glpk</a>
- </p></li><li>
- <code>lpsolve</code> (mixed integer linear programming)
- <p><a href="http://sourceforge.net/projects/lpsolve/">http://sourceforge.net/projects/lpsolve/</a>
- </p></li><li>
- <code>kinsol</code> (constrained non-linear optimization)
- <p><a href="http://www.llnl.gov/CASC/sundials/">http://www.llnl.gov/CASC/sundials/</a>
- </p></li></ul>
- </li><li> interoperability of virtual code applications with other console
- applications or shells through the <code>expect</code> library
- </li><li> a simple high-level
- interface to files, environment variables and command line parameters
- </li><li> support for various styles of stateless or persistent stream
- processors (a.k.a. Unix filters)
- </li></ul>
- <p>The reason for writing <code>avram</code> was that I wanted to do some work
- using a functional programming language, didn’t like any functional
- programming languages that already existed, and felt that it would be
- less trouble to write a virtual machine emulator than the back end of
- a compiler. As of version 0.1.0, the first public release of
- <code>avram</code> as such in 2000, most of the code base had been in heavy
- use by me for about four years, running very reliably. At this writing
- some six years later, it has seen even more use with rarely any
- reliability issues, in some cases attacking large combinatorial
- problems for weeks or months at a time. These problems have involved
- both long running continuous execution, and batches of thousands of
- shorter jobs.
- </p>
- <p>Although the virtual machine is biased toward functional programming,
- it is officially language agnostic, so <code>avram</code> may be useful to
- anyone involved in the development of compilers for other programming,
- scripting, or special purpose languages. The crucial advantage of
- using it in your own project is that rather than troubling over
- address modes, register allocation, and other hassles inherent in
- generating native code, your compiler can just dump a fairly high
- level intermediate code representation of the source text to a file,
- and let the virtual machine emulator deal with the details. The
- tradeoff for using a presumably higher level interpreted language is that the
- performance is unlikely to be competitive with native code, but this
- issue is mitigated in the case of numerical applications whose heavy
- lifting is done by the external libraries mentioned above.
- </p>
- <p>Portability is an added bonus. The virtual code is binary compatible
- across all platforms. Versions of <code>avram</code> as of 0.1.0 and later are
- packaged using GNU autotools and should be possible to build on any
- platform supporting them. In particular, the package is known to have
- built successfully on MacOS, FreeBSD, Solaris (thanks to the compile
- farm at Sourceforge.net) Digital Unix, and Debian GNU/Linux for i386 and
- Alpha platforms, although it has not been extensively tested on all of
- them. Earlier versions were compiled and run successfully on Irix and
- even Windows-NT (with <code>gcc</code>).
- </p>
- <p>This document is divided into three main parts, with possibly three
- different audiences, but they all depend on a basic familiarity with
- <a name="index-Unix-1"></a>
- Unix or GNU/Linux systems.
- </p>
- <dl compact="compact">
- <dt> <a href="User-Manual.html#User-Manual">User Manual</a></dt>
- <dd><p>essentially reproduces the information found in
- the manpage that is distributed with <code>avram</code> with a few extra
- examples and longer explanations. Properly deployed,
- <code>avram</code> should be almost entirely hidden from end users by wrapper
- scripts, so the “users” to whom this part is relevant would be
- those involved in preparing these scripts (a matter of choosing the right
- command line options). Depending on the extent to which this task is
- automated by a compiler, that may include the compiler writer or the
- developers of applications.
- </p></dd>
- <dt> <a href="Virtual-Machine-Specification.html#Virtual-Machine-Specification">Virtual Machine Specification</a></dt>
- <dd><p>documents much of what one would need to know in order to write a
- compiler that generates code executable by <code>avram</code>. That includes
- the complete virtual machine code semantics and file formats. It would
- also be possible to implement a compatible replacement for <code>avram</code>
- from scratch based on the information in this chapter, in case anyone
- has anything against C, my coding style, or the GPL. (A few patches to
- make it <code>lint</code> cleanly or a new implementation in good
- pedagogical Java without pointers would both be instructive
- exercises. ;-))
- <a name="index-pointers"></a>
- <a name="index-Java"></a>
- </p></dd>
- <dt> <a href="Library-Reference.html#Library-Reference">Library Reference</a></dt>
- <dd><p>includes documentation on the application program interface and
- recommended entry points for the C library distributed with
- <code>avram</code>. This information would be of use to those wishing to
- develop applications incorporating similar features, or to reuse the
- code for unrelated purposes. It might also be useful to anyone wishing
- to develop C or C++ applications that read or write data files in the
- format used by <code>avram</code>.
- </p></dd>
- </dl>
- <hr size="1">
- <table cellpadding="1" cellspacing="1" border="0">
- <tr><td valign="middle" align="left">[<a href="avram.html#Top" title="Previous section in reading order"> < </a>]</td>
- <td valign="middle" align="left">[<a href="User-Manual.html#User-Manual" title="Next section in reading order"> > </a>]</td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left">[ << ]</td>
- <td valign="middle" align="left">[<a href="avram.html#Top" title="Up section"> Up </a>]</td>
- <td valign="middle" align="left">[<a href="User-Manual.html#User-Manual" title="Next chapter"> >> </a>]</td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left"> </td>
- <td valign="middle" align="left">[<a href="avram.html#Top" title="Cover (top) of document">Top</a>]</td>
- <td valign="middle" align="left">[<a href="avram_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
- <td valign="middle" align="left">[<a href="Function-Index.html#Function-Index" title="Index">Index</a>]</td>
- <td valign="middle" align="left">[<a href="avram_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
- </tr></table>
- <p>
- <font size="-1">
- This document was generated on <i>November 8, 2012</i> using <a href="http://www.nongnu.org/texi2html/"><i>texi2html 1.82</i></a>.
- </font>
- <br>
- </p>
- </body>
- </html>
|