Skip to main content

Proving the Equivalence of Higher-Order Terms by Means of Supercompilation

  • Conference paper
Perspectives of Systems Informatics (PSI 2009)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 5947))

Abstract

One of the applications of supercompilation is proving properties of programs. We focus in this paper on a specific task: proving term equivalence for a higher-order lazy functional language. The “classical” way to prove equivalence of two terms t1 and t2 is to write an equality function equals and to simplify the term (equals t1 t2). However, this works only when certain conditions are met. The paper presents another approach to proving term equivalence by means of supercompilation. In this approach we supercompile both terms and compare supercompiled terms syntactically. Some applications of the technique are discussed. In particular, one of these applications may lead to the development of a more powerful “higher-level” supercompiler.

Supported by Russian Foundation for Basic Research projects No. 08-07-00280-a and No. 09-01-00834-a.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Albert, E., Vidal, G.: The narrowing-driven approach to functional logic program specialization. New Generation Computing 20(1), 3–26 (2002)

    Article  MATH  MathSciNet  Google Scholar 

  2. Alpuente, M., Falaschi, M., Vidal, G.: Partial evaluation of functional logic programs. ACM Transactions on Programming Languages and Systems (TOPLAS) 20(4), 768–844 (1998)

    Article  Google Scholar 

  3. Cockett, R.: Deforestation, program transformation, and cut-elimination. Electronic Notes in Theoretical Computer Science 44(1), 88–127 (2001)

    Article  Google Scholar 

  4. Dybjer, P., Filinski, A.: Normalization and partial evaluation. In: Barthe, G., Dybjer, P., Pinto, L., Saraiva, J. (eds.) APPSEM 2000. LNCS, vol. 2395, pp. 137–192. Springer, Heidelberg (2002)

    Chapter  Google Scholar 

  5. Glück, R., Klimov, A.V.: Occam’s razor in metacompuation: the notion of a perfect process tree. In: Cousot, P., Filé, G., Falaschi, M., Rauzy, A. (eds.) WSA 1993. LNCS, vol. 724, pp. 112–123. Springer, Heidelberg (1993)

    Google Scholar 

  6. Hamilton, G.W.: Distillation: extracting the essence of programs. In: Proceedings of the 2007 ACM SIGPLAN symposium on Partial evaluation and semantics-based program manipulation, pp. 61–70. ACM Press, New York (2007)

    Chapter  Google Scholar 

  7. Hamilton, G.W., Kabir, M.H.: Constructing programs from metasystem transition proofs. In: Proceedings of the First International Workshop on Metacomputation in Russia (2008)

    Google Scholar 

  8. Holst, C.K., Hughes, J.: Towards binding-time improvement for free. In: Functional Programming, Workshops in Computing, Glasgow. Springer, Heidelberg (1990)

    Google Scholar 

  9. Jonsson, P.A.: Positive supercompilation for a higher-order call-by-value language. Luleå University of Technology (2008)

    Google Scholar 

  10. Klimov, A.V.: A program specialization relation based on supercompilation and its properties. In: Proceedings of the First International Workshop on Metacomputation in Russia, pp. 54–78. Ailamazyan University of Pereslavl (2008)

    Google Scholar 

  11. Lisitsa, A., Nemytykh, A.P.: Reachability analysis in verification via supercompilation. International Journal of Foundations of Computer Science 19(4), 953–969 (2008)

    Article  MATH  MathSciNet  Google Scholar 

  12. Lisitsa, A.P., Nemytykh, A.P.: Verification as a parameterized testing (experiments with the scp4 supercompiler). Programming and Computer Software 33(1), 14–23 (2007)

    Article  MATH  Google Scholar 

  13. Lisitsa, A.P., Webster, M.: Supercompilation for equivalence testing in metamorphic computer viruses detection. In: Proceedings of the First International Workshop on Metacomputation in Russia. Ailamazyan University of Pereslavl (2008)

    Google Scholar 

  14. Mitchell, N., Runciman, C.: A supercompiler for core haskell. In: Chitil, O., Horváth, Z., Zsók, V. (eds.) IFL 2007. LNCS, vol. 5083, pp. 147–164. Springer, Heidelberg (2008)

    Chapter  Google Scholar 

  15. Pitts, A.M.: Operationally-based theories of program equivalence. In: Semantics and Logics of Computation, pp. 241–298 (1997)

    Google Scholar 

  16. Romanenko, S.A.: Higher-order functions as a substitute for partial evaluation. In: Proceedings of the First International Workshop on Metacomputation in Russia. Ailamazyan University of Pereslavl (2008)

    Google Scholar 

  17. Sørensen, M.H., Glück, R., Jones, N.D.: A positive supercompiler. Journal of Functional Programming 6(6), 811–838 (1993)

    Article  Google Scholar 

  18. Turchin, V.F.: The Language Refal: The Theory of Compilation and Metasystem Analysis. Department of Computer Science, Courant Institute of Mathematical Sciences, New York University (1980)

    Google Scholar 

  19. Turchin, V.F.: The concept of a supercompiler. ACM Transactions on Programming Languages and Systems (TOPLAS) 8(3), 292–325 (1986)

    Article  MATH  MathSciNet  Google Scholar 

  20. Turchin, V.F.: Metacomputation: Metasystem transitions plus supercompilation. In: Danvy, O., Thiemann, P., Glück, R. (eds.) Dagstuhl Seminar 1996. LNCS, vol. 1110, pp. 481–509. Springer, Heidelberg (1996)

    Google Scholar 

  21. Turner, D.A.: Total functional programming. Journal of Universal Computer Science 10(7), 751–768 (2004)

    MathSciNet  Google Scholar 

  22. Wadler, P.: Theorems for free! In: FPCA 1989: Proceedings of the fourth international conference on Functional programming languages and computer architecture, pp. 347–359. ACM, New York (1989)

    Chapter  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2010 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Klyuchnikov, I., Romanenko, S. (2010). Proving the Equivalence of Higher-Order Terms by Means of Supercompilation. In: Pnueli, A., Virbitskaite, I., Voronkov, A. (eds) Perspectives of Systems Informatics. PSI 2009. Lecture Notes in Computer Science, vol 5947. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-11486-1_17

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-11486-1_17

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-11485-4

  • Online ISBN: 978-3-642-11486-1

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics