Skip to main content

Using subtyping in program optimization

  • Conference paper
  • First Online:
Typed Lambda Calculi and Applications (TLCA 1995)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 902))

Included in the following conference series:

Abstract

Constructive logics can be used to write the specifications of programs as logic formulas to be proved. By using the Curry-Howard isomorphism, we can automatically extract executable code from constructive proofs. Normally, programs automatically generated are inefficent. They contains parts useless to compute the final result. In this paper, we show a technique to erase such useless parts from programs. Our technique is essentially an extension of another method, developed by S. Berardi, optimizing simply typed λ-terms. By using the notion of subtyping, we can overcome some intrinsecal limitations of the original method. We prove that optimized terms are equivalent to the original ones and we give an algorithm to find such optimizations

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

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. M. Beeson, Foundations of Constructive Mathematics, Berlin, Springer-Verlag, 1985

    Google Scholar 

  2. S. Berardi, An Application of PER Models to Program Extraction, Technical Report, Turin University, 1992.

    Google Scholar 

  3. S. Berardi, Pruning Simply Typed λ-terms, Technical Report, Turin University, 1993.

    Google Scholar 

  4. L. Boerio, Extending Pruning Techniques to Polymorphic Second Order λ-Calculus, Proceedings of ESOP '94, Edinburgh, April 1994, LNCS 788, D. Sannella (ed.), Springer-Verlag, pp. 120–134.

    Google Scholar 

  5. C. Paulin-Mohring, Extracting F ω 's Programs from Proofs in the Calculus of Constructions, In: Association for Computing Machinery, editor, Sixteenth Annual ACM Symposium on Priciples of Programming Languages, 1989.

    Google Scholar 

  6. Y. Takayama, Extraction of Redundancy-free Programs from Constructive Natural Deduction Proofs, Journal of Symbolic Computation, 1991, 12, 29–69

    Google Scholar 

  7. A. S. Troelstra, Mathematical Investigation of Intuitionistic Arithmetic and Analysis, Lecture Notes in Mathematics, 344, Springer-Verlag, 1973

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Mariangiola Dezani-Ciancaglini Gordon Plotkin

Rights and permissions

Reprints and permissions

Copyright information

© 1995 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Berardi, S., Boerio, L. (1995). Using subtyping in program optimization. In: Dezani-Ciancaglini, M., Plotkin, G. (eds) Typed Lambda Calculi and Applications. TLCA 1995. Lecture Notes in Computer Science, vol 902. Springer, Berlin, Heidelberg. https://doi.org/10.1007/BFb0014045

Download citation

  • DOI: https://doi.org/10.1007/BFb0014045

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-59048-4

  • Online ISBN: 978-3-540-49178-1

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics