On the Efficiency of Optimising Shallow Backtracking in Prolog
Number of Authors: 1
1990 (English)Report (Refereed)
The cost of backtracking has been identified as one of the bottlenecks in achieving peak performance in compiled Prolog programs. Much of the backtracking in Prolog programs is shallow, i.e. is caused by unification failures in the head of a clause when there are more alternatives for the same procedure, and so special treatment of this form of backtracking has been proposed as a significant optimisation. This paper describes a modified WAM which optimises shallow backtracking. Four different implementation approaches are compared. A number of benchmark results are presented, measuring the relative tradeoffs between compilation time, code size, and run time. The results show that the speedup gained by this optimisation can be significant.
Place, publisher, year, edition, pages
Kista, Sweden: Swedish Institute of Computer Science , 1990, 1. , 14 p.
SICS Research Report, ISSN 0283-3638 ; R90:03
Computer and Information Science
IdentifiersURN: urn:nbn:se:ri:diva-14024OAI: oai:DiVA.org:ri-14024DiVA: diva2:1035307
Original report number R90003.2016-10-132016-10-13