A Reactive Implementation of Pos Using ROBDDs

The subject of groundness analysis for (constraint) logic programs has been widely studied, and interesting domains have been proposed. Pos has been recognized as the most suitable domain for capturing the kind of dependencies arising in groundness analysis. Its (by now standard) implementation is based on reduced ordered binary-decision diagrams (ROBDDs), a well-known symbolic representation for Boolean functions. Even though several authors have reported positive experiences using ROBDDs for groundness analysis, in the literature there is no reference to the problem of the efficient detection of those variable which are deemed to be ground in the context of a ROBDD. This is not surprising, since most currently implemented analyzers need to derive this information only at the end of the analysis and only for presentation purposes. Things are much different when this information is required during the analysis. This need arises when dealing with languages which employ some sort of delay mechanism, which are typically based on groundness conditions. In these cases, the naif approaches are too inefficient, since the abstract interpreter must quickly (and often) decide whether a constraint is delayed or not. Fast access to ground variables is also necessary when aliasing analysis is performed using a domain not keeping track of ground dependencies. In this paper we introduce and study the problem, proposing two possible solutions. The second one, besides making possible the quick detection of ground variables, has also the effect of keeping the ROBDDs as small as possible, improving the efficiency of groundness analysis in itself.

[1]  Vijay A. Saraswat,et al.  Concurrent constraint programming , 1989, POPL '90.

[2]  A. Cortesi,et al.  Prop revisited: propositional formula as abstract domain for groundness analysis , 1991, [1991] Proceedings Sixth Annual IEEE Symposium on Logic in Computer Science.

[3]  Randal E. Bryant,et al.  Symbolic Boolean manipulation with ordered binary-decision diagrams , 1992, CSUR.

[4]  Roberto Bagnara,et al.  An application of constraint propagation to data-flow analysis , 1993, Proceedings of 9th IEEE Conference on Artificial Intelligence for Applications.

[5]  Roberto Bagnara,et al.  A Hierarchy of Constraint Systems for Data-Flow Analysis of Constraint Logic-Based Languages , 1998, Sci. Comput. Program..

[6]  Pascal Van Hentenryck,et al.  Groundness analysis for Prolog: implementation and evaluation of domain prop , 1993, PEPM '93.

[7]  Dean Jacobs,et al.  Accurate and Efficient Approximation of Variable Aliasing in Logic Programs , 1989, NACLP.

[8]  Saumya K. Debray,et al.  Static inference of modes and data dependencies in logic programs , 1989, TOPL.

[9]  Pascal Van Hentenryck,et al.  Evaluation of the Domain Prop , 1995, J. Log. Program..

[10]  Randal E. Bryant,et al.  Graph-Based Algorithms for Boolean Function Manipulation , 1986, IEEE Transactions on Computers.

[11]  Kim Marriott,et al.  Two Classes of Boolean Functions for Dependency Analysis , 1998, Sci. Comput. Program..

[12]  Roberto Bagnara,et al.  On the Detection of Implicit and Redundant Numeric Constraint in CLP Programs , 1994, GULP-PRODE.

[13]  Agostino Cortesi,et al.  Conceptual and Software Support for Abstract Domain Design: Generic Structural Domain and Open Product , 1993 .

[14]  Roland H. C. Yap,et al.  The CLP( R ) language and system , 1992, TOPL.

[15]  Patrick Cousot,et al.  Systematic design of program analysis frameworks , 1979, POPL.

[16]  Patrick Cousot,et al.  Abstract Interpretation and Application to Logic Programs , 1992, J. Log. Program..

[17]  Pascal Van Hentenryck,et al.  Combinations of abstract domains for logic programming , 1994, POPL '94.

[18]  Chris Mellish,et al.  Some Global Optimizations for a Prolog Compiler , 1985, J. Log. Program..