Title
Constraint-based mode analysis of mercury
Abstract
Recent logic programming languages, such as Mercury and HAL, require type, mode and determinism declarations for predicates. This information allows the generation of efficient target code and the detection of many errors at compile-time. Unfortunately, mode checking in such languages is difficult. One of the main reasons is that, for each predicate mode declaration, the compiler is required to decide which parts of the procedure bind which variables, and how conjuncts in the predicate definition should be re-ordered to enforce this behaviour. Current mode checking systems limit the possible modes that may be used because they do not keep track of aliasing information, and have only a limited ability to infer modes, since inference does not perform reordering. In this paper we develop a mode inference system for Mercury based on mapping each predicate to a system of Boolean constraints that describe where its variables can be produced. This allows us handle programs that are not supported by the existing system.
Year
DOI
Venue
2002
10.1145/571157.571169
PPDP
Keywords
Field
DocType
predicate definition,existing system,current mode checking system,determinism declaration,boolean constraint,mode checking,constraint-based mode analysis,predicate mode declaration,aliasing information,possible mode,mode inference system,modes
Declaration,Programming language,Determinism,Computer science,Inference,Compiler,Theoretical computer science,Aliasing,Predicate (grammar),Logic programming,Predicate (mathematical logic)
Conference
ISBN
Citations 
PageRank 
1-58113-528-9
12
0.90
References 
Authors
16
3
Name
Order
Citations
PageRank
David Overton1120.90
Zoltan Somogyi2571141.85
Peter J. Stuckey34368457.58