Prehistory ---------- We designed the Mercury execution algorithm in October 1993. We started working on a Mercury compiler in December 1993. Semantic analysis started working around May 1994. We started generating code around August 1994; we started work on optimizations very soon after. The compiler successfully compiled itself on 24 February 1995. Mercury 0.1, April 8 1995 ------------------------- Initial beta-test release. Very resource-hungry, not very well documented. Mercury 0.2, April 18 1995 -------------------------- Much better error messages for determinism errors, much faster compilation, much lower memory requirements for bootstrapping. The C compilation is much faster and requires much less memory since we now by default compile to one C function per procedure, but we also improved the speed of the Mercury compiler itself by nearly 40% by implementing some library predicates much more efficiently. Mercury 0.2.5, 1 June 1995 -------------------------- Much better syntax error messages. Better documentation, now including a library reference manual. Added a GNU autoconf configuration script. Ported to IRIX 5. Added `multidet'. Enabled the use of tag bits in combination with conservative garbage collection (this improved the speed of the compiler by about 20%). Compile directly to C rather than via the old .mod files, which were post-processed by a Perl script (improves compilation speed, reduces disk space requirements, removes dependency on Perl). Lots of bug fixes. Mercury 0.3, 18 July 1995 ----------- The first public release. Better type error messages. Better determinism error messages. Only recompiles _init.c after `mmake depend', rather than after anything changes. Ported to ULTRIX (N.B. - ULTRIX's /bin/sh sucks). Avoid saving variables on the stack before negated contexts. Don't embed label names as strings in the executable. A few other efficiency improvements. Lots of bug fixes. Made the rule for `mmake clean' less reckless (don't do `rm -f *.c'). Rationalized the options to `mc'. Implemented a couple of new ones. Added a symbol demangler to improve linker error messages. Made very significant improvements to the documentation. Added a "Prolog to Mercury transition guide". Mercury 0.4, 14 September 1995 ------------------------------ * Higher-order predicates and lambda expressions are now implemented. (This means that `call/{1,2,3,4}' and `solutions/2' are now usable; unfortunately call/{5,6,...} are still not yet implemented.) * Unique modes are now partially implemented (but don't use them for anything except I/O, as the implementation is not yet complete). * Partially instantiated modes are now closer to being fully implemented. * The installation process is more standard (basically just `configure; make; make install'). * Autoconfiguration is a bit more robust. * `msc' and `mnc' now produce somewhat smaller object files. * Error and warning messages are a little better in some cases. * Fixed a few code generation bugs. * Ported to DEC Alpha/OSF and BSDI BSD/386. * We've improved the efficiency of the 386 port by about 70%. (50% because asm_fast.gc mode now works on the 386, the rest due to better optimization). * We generate better code for calls to `\='. * We generate better code for `compare/3'. * A few other new optimizations. * The profiler now works (see the documentation in the Mercury User's Guide). * Some new library predicates, including `string__format' (like C's sprintf). * `set__join/2' has been renamed as `set__power_union/2'. * `list__sort/2' has been renamed as `list__sort_and_remove_dups/2'. * There is a new `list__sort/2' which does not remove duplicates. Mercury 0.5, 15 Febuary 1995 ---------------------------- * We now support committed choice nondeterminism in a logical and declarative fashion, using the new determinism categories `cc_nondet' and `cc_multi'. Like `nondet' and `multi' respectively, they specify that a predicate may have more than one solution, but they convey the additional assertion that the predicate will only be used in contexts in which only one solution is needed. The compiler will check that all uses of the predicate satisfy this requirement. Having proven the assertion to be correct, the compiler can then generate much more efficient code for the predicate. By pushing pruning inwards, the compiler can often avoid creating choice points at all. * We now check for backtracking over unique modes. (This may potentially break some programs using unique modes in ways that the compiler can't prove are safe. In such cases, replacing `multi' with `cc_multi' should solve the problem. If you have any trouble with this, we'll be happy to help you.) We have also added "mostly unique" modes, which provide support for backtrackable destructive update. See the Mercury language reference manual. * We now provide genuinue arrays with destructive update. See the library module `uniq_array'. (Warning: this has not had much testing. The interface is not yet stable.) * We now support interfacing to C code. See the documentation in the Mercury language reference manual. * There is now an `inline' pragma which you can use as a hint to the compiler to inline a particular predicate. * We've ported the system to ULTRIX (thanks to Gertjan van Noord and especially Eero Pajarre). * We now support shared libraries for IRIX 5. * We now allow the use of compilers other than gcc - see the user's guide for details. We don't recommend the use of compilers other than gcc, since the inability to use gcc's special features will most likely lead to much less efficient code. * To complement our source distribution, we now also provide binary distributions for a variety of platforms. Installation should be quick and easy. * Various other minor improvements: - In portable C mode, we now generate better code for loops. - We've made a few other minor improvements in the generated code. - Unary plus and minus are now implemented. - Updated the documentation to reflect changes in unique modes, - Corrected a lot of typos in the documentation. - Fixed quite a few bugs. * Parts of the library module `std_util' have been moved into separate modules `assoc_list' and `bool'; if you have existing code which used those parts of `std_util', you may need to add `import_module' declarations to import `assoc_list' and/or `bool'.