Caml-Light

Caml-light is an implementation of the CAML dialect of the ML language. It can be found at ftp.inria.fr:lang/caml-light. This is a product of the Cristal Project at INRIA.

Overview:

Caml Light is a small, portable implementation of the ML language. that runs on most Unix machines. It has also been ported to the Macintosh and to the IBM PC.

Caml Light implements the Caml language, a functional language from the ML family. Caml is quite close to Standard ML, though not strictly conformant. There are some slight differences in syntax and semantics, and major differences in the module system (these changes were required to support separate compilation).

Caml Light is implemented as a bytecode compiler, and fully bootstrapped. The runtime system and bytecode interpreter is written in standard C, hence Caml Light is easy to port to almost any 32-bit platform. The whole system is quite small: about 100K for the runtime system, and another 100K of bytecode for the compiler. 1.2 megabyte of memory is enough to recompile the whole system. This stands in sharp contrast with other implementations of ML, such as SML-NJ, that requires about ten times more memory. Performance is quite good for a bytecoded implementation: five to ten times slower than SML-NJ.

Caml Light comes in two flavors: a classical, interactive, toplevel-based system; and a standalone, batch-oriented compiler that produces standalone programs, in the spirit of the Unix cc compiler. The former is good for learning the language and testing programs. The latter integrates more smoothly within programming environments. The generated programs are quite small, and can be used like any other command.