ECLiPSe Features

Overview

ECLiPSe is a Constraint Logic Programming (CLP) system, consisting of

ECLiPSe is intended for

The textbook Constraint Logic Programming using ECLiPSe by Apt&Wallace covers many of these aspects.

For further reading, see the introductory paper ECLiPSe as a Platform for Constraint Logic Programming and the tutorial-style document ECLiPSe - An Introduction.

ECLiPSe has also been discussed in a BYTE article about CLP.

A two-page feature overview leaflet (pdf, word) is available.

Development Environment

tkeclipse development GUI on both Unix and Windows (screen shot (31k))

Traditional command-line based development system also supported.

Debugger working on compiled code.

Profiling tool to collect timings of the execution of individual predicates.

Detailed documentation in printable form, and online-accessible in html format and from the development system.

System Architecture

Incremental compiler. Optimizes index selection, unification order, inlining of control constructs and takes mode information into account.

The system is designed to impose no unnecessary limits on programs and data. E.g. there is no limit, other than the available memory, on the number or length of atoms and strings, the arity of functors, the code size, number of procedures, complexity of clauses or stack sizes.

Synchronous and asynchronous event handling, used for both error and exception handling as well as for interfacing to external event sources.

Fully automatic memory management with garbage collection for stacks and dictionary.

Highly configurable syntax and behaviour.

ECLiPSe programs can execute in or-parallel on shared-memory multiprocessor hardware (this functionality is currently not actively maintained because of other priorities).

A complete I/O system based on the notion of abstract streams which can be connected to files, ttys, pipes, sockets, or in-memory strings and queues.

Core Language Features

ECLiPSe is backward-compatible with Prolog (supporting the ISO/IEC 13211-1/TC1/TC2 standard, as well as other dialects). Here are some classic benchmark results.

ECLiPSe provides comprehensive facilities to implement data-driven control behaviour. These include declarative delay-clauses as well as primitives for meta-programmed control like explicit goal suspension, flexible triggering facilities and execution priorities.

The attributed variable data type is the key to many extensions to the basic Logic Programming language. The system calls user-definable event handlers when it encounters attributed variables in certain contexts, e.g. unification.

Full module system, controlling the scope of visibility of predicates, non-logical stores, macros and syntax settings. Modules can be used both to structure applications and to restrict access to the implementation details.

String data type with garbage-collectable strings.

Arithmetics with unlimited precision integers, rational numbers, single and double precision floats, and floating point intervals with safe rounding.

Logical iteration construct which often eliminates the need for recursive predicates.

Logical arrays.

Structures with field names.

Matching clauses.

Global references and variables.

Libraries

Constraint solvers. ECLiPSe provides several libraries of constraint solvers which can be used in application programs:

Solver Interfaces. ECLiPSe interfaces to the COIN-OR, CPLEX, Gurobi and XPRESS-MP linear and mixed-integer programming solvers, and the Gecode finite-domain solver. Other interfaces are under development.

Various other utility libraries, including a number of public-domain ones, are included in the distribution.

Language Compatibility

The ECLiPSe programming language belongs to the Prolog family of languages. This family includes the ISO Standard ISO/IEC 13211-1 (1995/2007/2012) and a number of other popular and influential implementation dialects. Where possible, ECLiPSe follows the standard and/or common practice. Where conflicts exist, compatibility modules are provided. These make it possible to integrate components written in different dialects into a single ECLiPSe application. Fully supported dialects are ISO and C-Prolog, partial support exists for Quintus, SICStus and SWI.

Embedding and Interfaces

Tight interface to C and C++. ECLiPSe code can call C/C++ code, or a C/C++ main program can call ECLiPSe as a library. Data can be converted between C and ECLiPSe representations, or alternatively, ECLiPSe data can be referenced from C/C++ and C/C++ data can be referenced from ECLiPSe.

Loose interface for embedding or remote connection to Tcl/Tk and Java host applications. The main characteristics of these interfaces are bi-directional event-driven communication and the ability to communicate complex data structures through a language-independent data representation.