Programming in Prolog (2nd ed.)
Programming in Prolog (2nd ed.)
A view of the origins and development of Prolog
Communications of the ACM
A Parallel Unification Machine
IEEE Micro
Efficient Reordering of Prolog Programs
IEEE Transactions on Knowledge and Data Engineering
Hi-index | 0.00 |
PROLOG uses a depth-first search of an AND/OR graph to satisfy queries against its database. It searches sequentially through the clauses of a predicate whose head matches the query, trying to satisfy the goals in the clause body in a sequential left-to-right order. The ordering of clauses and goals is a major factor in the efficiency of a PROLOG program. We have developed a profiler for C-PROLOG that collects statistics including the failure rate of clauses and goals in a C-PROLOG program. These statistics are used by any of several reordering predicates capable of local or global reordering. The intent is to construct a reordered PROLOG program that outputs an equivalent set of answers, and is more efficient. Test results are promising.