Efficient Access Mechanisms for Tabled Logic Programs

Abstract

The use of tabling in logic programming allows bottom-up evaluation to be incorporated in a top-down framework, combining advantages of both. At the engine level, tabling also introduces issues not present in pure top-down evaluation, due to the need for subgoais and answers to access tables during resolution. This article describes the design, implementation, and experimental evaluation of data structures and algorithms for high-performance table access. Our approach uses tries as the basis for tables. Tries, a variant of discrimination nets, provide complete discrimination for terlns, and permit a lookup and possible insertion to be performed in a single pass through a term. In addition, a .aovel technique of substituthm ,factor#lg is proposed. When substitution factoring is used, the access cost for answers is proportional to the size of the answer substitution, rather than to the size of the answer itsell, Answer tries can be implemented both as interpreted structures and as compiled WAM-like code. When they are compiled, the speed of computing substitutions through answer tries is competitive with the speed of unit facts compiled or asserted as WAM code. Because answer tries can also be created an order of magnitude more quickly than asserted code, they form a promising alternative for representing certain types of dynamic code, even in Prolog systems without tabling. © 1999 Elsevier Science Inc. All rights reserved.

DOI: 10.1016/S0743-1066(98)10013-4

Extracted Key Phrases

18 Figures and Tables

Statistics

051015'00'02'04'06'08'10'12'14'16
Citations per Year

96 Citations

Semantic Scholar estimates that this publication has 96 citations based on the available data.

See our FAQ for additional information.

Cite this paper

@article{Ramakrishnan1999EfficientAM, title={Efficient Access Mechanisms for Tabled Logic Programs}, author={I. V. Ramakrishnan and Prasad Rao and Konstantinos Sagonas and Theresa Swift and David Scott Warren}, journal={J. Log. Program.}, year={1999}, volume={38}, pages={31-54} }