A Comparison of Three Occur-Check Analysers. Crnogorac, L., Kelly, A., & Søndergaard, H. In Cousot, R. & Schmidt, D. A., editors, Static Analysis: Proceedings of the Third International Symposium, volume 1145, of Lecture Notes in Computer Science, pages 159–173, 1996. Springer.
doi  abstract   bibtex   
A well known problem with many Prolog interpreters and compilers is the lack of occur-check in the implementation of the unification algorithm. This means that such systems are unsound with respect to first-order predicate logic. Static analysis offers an appealing approach to the problem of occur-check reduction, that is, the safe omission of occur-checks in unification. We compare, for the first time, three static methods that have been suggested for occur-check reduction, two based on assigning ``modes'' to programs and one which uses abstract interpretation. In each case, the analysis or some essential part of it had not been implemented so far. Of the mode-based methods, one is due to Chadha and Plaisted and the other is due to Apt and Pellegrini. The method using abstract interpretation is based on earlier work by Plaisted, Søndergaard and others who have developed groundness and sharing analyses for logic programs. The conclusion is that a truly global analysis based on abstract interpretation leads to markedly higher precision and hence fewer occur-checks at run-time. Given the potential run-time speedups, a precise analysis would be well worth the extra time.
@Inproceedings{Crn-Kel-Son_SAS96,
  author    = {Lobel Crnogorac and 
		Andrew Kelly and 
		Harald S{\o}ndergaard},
  title     = {A Comparison of Three Occur-Check Analysers},
  editor    = {R. Cousot and D. A. Schmidt},
  booktitle = {Static Analysis: Proceedings of the Third International 
		Symposium},
  series    = {Lecture Notes in Computer Science},
  volume    = {1145},
  pages     = {159--173},
  publisher = {Springer},
  year      = {1996},
  doi       = {10.1007/3-540-61739-6_40},
  abstract  = {A well known problem with many Prolog interpreters and compilers
		is the lack of occur-check in the implementation of the 
		unification algorithm. This means that such systems are unsound
		with respect to first-order predicate logic. Static analysis 
		offers an appealing approach to the problem of occur-check 
		reduction, that is, the safe omission of occur-checks in 
		unification. We compare, for the first time, three static 
		methods that have been suggested for occur-check reduction, 
		two based on assigning ``modes'' to programs and one which 
		uses abstract interpretation. In each case, the analysis or 
		some essential part of it had not been implemented so far.
		Of the mode-based methods, one is due to Chadha and Plaisted
		and the other is due to Apt and Pellegrini. The method using 
		abstract interpretation is based on earlier work by Plaisted, 
		S{\o}ndergaard and others who have developed groundness and 
		sharing analyses for logic programs. The conclusion is that a 
		truly global analysis based on abstract interpretation leads 
		to markedly higher precision and hence fewer occur-checks at 
		run-time. Given the potential run-time speedups, a precise 
		analysis would be well worth the extra time.},
  keywords  = {Abstract interpretation, Groundness analysis, Sharing analysis, Unification, Prolog, Compilation},
}

Downloads: 0