Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1007/978-3-642-11486-1_35guideproceedingsArticle/Chapter ViewAbstractPublication PagesConference Proceedingsacm-pubtype
Article

Anti-unification algorithms and their applications in program analysis

Published: 15 June 2009 Publication History

Abstract

A term t is called a template of terms t1 and t2 iff t1=1 and t2=2, for some substitutions η1 and η2. A template t of t1 and t2 is called the most specific iff for any template t′ of t1 and t2 there exists a substitution ξ such that t=tξ. The anti-unification problem is that of computing the most specific template of two given terms. This problem is dual to the well-known unification problem, which is the computing of the most general instance of terms. Unification is used extensively in automatic theorem proving and logic programming. We believe that anti-unification algorithms may have wide applications in program analysis. In this paper we present an efficient algorithm for computing the most specific templates of terms represented by labelled directed acyclic graphs and estimate the complexity of the anti-unification problem. We also describe techniques for invariant generation and software clone detection based on the concepts of the most specific templates and anti-unification.

References

[1]
Baader, F., Snyder, W.: Unification theory. In: Robinson, J. A., Voronkov, A. (eds.) Handbook of Automated Reasoning, vol. 1, pp. 447-533 (2001)
[2]
Baxter, I., Yahin, A., Moura, L. M., Sant'Anna, M., Bier, L.: Clone Detection Using Abstract Syntax Trees. In: Proc. of the 14th IEEE International Conference on Software Maintenance, pp. 368-377 (1998)
[3]
Bille, P.: A survey on tree distance and related problems. Theoretical Computer Science 337(1-3), 217-239 (2005)
[4]
Bulychev, P.: Duplicate code detection using Clone Digger. PythonMagazine 9, 18-24 (2008)
[5]
Bulychev, P., Minea, M.: An evaluation of duplicate code detection using antiunification. In: Proc. of the 3rd Int. Workshop on Software Clones, pp. 22-27 (2009)
[6]
Eder, E.: Properties of substitutions and unifications. Journal of Symbolic Computations 1, 31-46 (1985)
[7]
Evans, W., Fraser, C., Ma, F.: Clone detection via structural abstraction. In: Proc. of 14th Working Conference on Reverse Engineering, pp. 150-159 (2007)
[8]
Kovac, L. I., Jebelean, T.: An algorithm for automated generation of invariants for loops with conditionals. In: Proc. of the 7th Int. Symp. on Symbolic and Numeric Algorithms for Scientific Computing, pp. 245-250 (2005)
[9]
Nielson, F., Nielson, H. R., Hankin, C.: Principles of program analysis, 446 p. Springer, Heidelberg (1999)
[10]
Oancea, C. E., So, C., Watt, S. M.: Generalization in Maple. In: Maple Conference, pp. 277-382 (2005)
[11]
Palamidessi, C.: Algebraic properties of idempotent substitutions. In: Paterson, M. (ed.) ICALP 1990. LNCS, vol. 443, pp. 386-399. Springer, Heidelberg (1990)
[12]
Plotkin, G. D.: A note on inductive generalization. Machine Intelligence 5(1), 153- 163 (1970)
[13]
Reynolds, J.C.: Transformational systems and the algebraic structure of atomic formulas. Machine Intelligence 5(1), 135-151 (1970)
[14]
Roy, C. K., Cordy, J. R.: A survey on software clone detection research. Technical Report N 2007-541, School of Computing Queen's University at Kingston Ontario, Canada
[15]
Sorensen, M. H.: Gluck. R. An algorithm of generalization in positive supercompilation. In: Proc. of the 1995 Int. Symposium on Logic Programming, pp. 465-479. MIT Press, Cambridge (1995)
[16]
Tiwari, A., Rueb, H., Saidi, H., Shankar, N.: A technique for invariant generation. In: Margaria, T., Yi, W. (eds.) TACAS 2001. LNCS, vol. 2031, pp. 113-127. Springer, Heidelberg (2001)
[17]
Watt, S. M.: Algebraic generalization. ACM SIGSAM Bulletin 39(3), 93-94 (2005)
[18]
Wettel, R., Marinescu, R.: Archeology of Code Duplication: Recovering Duplication Chains From Small Duplication Fragments. In: Proc. of the 7th Int. Symb. on Symbolic and Numeric Algorithms for Scientific Computing, pp. 63-70 (2005)

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image Guide Proceedings
PSI'09: Proceedings of the 7th international Andrei Ershov Memorial conference on Perspectives of Systems Informatics
June 2009
423 pages
ISBN:3642114857
  • Editors:
  • Amir Pnueli,
  • Irina Virbitskaite,
  • Andrei Voronkov

Sponsors

  • INTEL: Intel Corporation
  • HP LABS (UK): HP LABS (UK)
  • Google Inc.
  • Microsoft Research: Microsoft Research
  • RFBR: Russian Foundation for Basic Research

Publisher

Springer-Verlag

Berlin, Heidelberg

Publication History

Published: 15 June 2009

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)0
  • Downloads (Last 6 weeks)0
Reflects downloads up to 12 Feb 2025

Other Metrics

Citations

Cited By

View all
  • (2024)API usage templates via structural generalizationJournal of Systems and Software10.1016/j.jss.2024.111974210:COnline publication date: 1-Apr-2024
  • (2024)Global guidance for local generalization in model checkingFormal Methods in System Design10.1007/s10703-023-00412-363:1-3(81-109)Online publication date: 1-Oct-2024
  • (2018)Finding parallel functional pearlsFuture Generation Computer Systems10.1016/j.future.2017.07.02479:P2(669-686)Online publication date: 1-Feb-2018
  • (2017)Unranked second-order anti-unificationInformation and Computation10.1016/j.ic.2017.01.005255:P2(262-286)Online publication date: 1-Aug-2017
  • (2016)Verified lifting of stencil computationsACM SIGPLAN Notices10.1145/2980983.290811751:6(711-726)Online publication date: 2-Jun-2016
  • (2016)Verified lifting of stencil computationsProceedings of the 37th ACM SIGPLAN Conference on Programming Language Design and Implementation10.1145/2908080.2908117(711-726)Online publication date: 2-Jun-2016
  • (2014)Monads for the formalization of a pattern matching procedureProgramming and Computing Software10.1134/S036176881403007440:3(117-127)Online publication date: 1-May-2014
  • (2014)Unranked Second-Order Anti-UnificationProceedings of the 21st International Workshop on Logic, Language, Information, and Computation - Volume 865210.1007/978-3-662-44145-9_5(66-80)Online publication date: 1-Sep-2014
  • (2014)A Library of Anti-unification AlgorithmsProceedings of the 14th European Conference on Logics in Artificial Intelligence - Volume 876110.1007/978-3-319-11558-0_38(543-557)Online publication date: 24-Sep-2014
  • (2012)Learning gestures for interacting with low-fidelity prototypesProceedings of the First International Workshop on Realizing AI Synergies in Software Engineering10.5555/2666527.2666534(32-36)Online publication date: 5-Jun-2012

View Options

View options

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media