Abstract
Focusing is a technique from proof theory that exploits type information to prune inessential nondeterminism from proof search procedures. Viewed through the lens of the Curry-Howard correspondence, a focused typing derivation yields terms in normal form. This paper explores how to exploit focusing for reasoning about contextual equivalences and full abstraction. We present a focused polymorphic call-by-push-value calculus and prove a computational completeness result: for every well-typed term, there exists a focused term that is βη-equivalent to it. This completeness result yields a powerful way to refine the context lemmas for establishing contextual equivalences, cutting down the set that must be considered to just focused contexts. The paper demonstrates the application of focusing to establish program equivalences, including free theorems. It also uses focusing to prove full abstraction of a translation of the pure, total call-by-push-value language into a language with divergence and simple effect types, yielding a novel solution to a simple-to-state, but hitherto difficult to solve problem.
Supplemental Material
- Andreas Abel. 2008. Weak-Normalization and Normalization by Evaluation for System F. In 15th International Conference on Logic for Programming, Artificial Intelligence, and Reasoning, LPAR 2008, 22-27 November 2008, Doha, Qatar, Proceedings (Lecture Notes in Artificial Intelligence), Illiano Cervesato, Helmut Veith, and Andrei Voronkov (Eds.), Vol. 5330. SpringerVerlag, 497-511.Google Scholar
Digital Library
- Andreas Abel and Christian Sattler. 2019. Normalization by Evaluation for Call-By-Push-Value and Polarized Lambda Calculus. In Proceedings of the 21st International Symposium on Principles and Practice of Programming Languages 2019 (PPDP '19). Association for Computing Machinery, New York, NY, USA, Article 3, 12 pages.Google Scholar
Digital Library
- Samson Abramsky. 1990. The Lazy-Calculus. In Research topics in functional programming. Addison Wesley, 65-116.Google Scholar
- Samson Abramsky and C-H Luke Ong. 1993. Full abstraction in the lazy lambda calculus. Information and Computation 105, 2 ( 1993 ), 159-267.Google Scholar
- Amal Ahmed and Matthias Blume. 2008. Typed Closure Conversion Preserves Observational Equivalence. SIGPLAN Not. 43, 9 ( 2008 ), 157-168.Google Scholar
- Amal Ahmed and Matthias Blume. 2011. An Equivalence-preserving CPS Translation via Multi-language Semantics. SIGPLAN Not. 46, 9 ( 2011 ), 431-444.Google Scholar
- Jean-Marc Andreoli. 1992. Logic programming with focusing proofs in linear logic. Journal of logic and computation 2, 3 ( 1992 ), 297-347.Google Scholar
Cross Ref
- Taus Brock-Nannestad and Carsten Schürmann. 2010. Focused Natural Deduction. In Proceedings of the 17th International Conference on Logic for Programming, Artificial Intelligence, and Reasoning (LPAR'10). Springer-Verlag, Berlin, Heidelberg, 157-171.Google Scholar
Digital Library
- Kaustuv Chaudhuri, Frank Pfenning, and Greg Price. 2018. A logical characterization of forward and backward chaining in the inverse method. Journal of Automated Reasoning 40, 2-3 ( 2018 ), 133-177.Google Scholar
- J. W. Debakker and Dana S. Scott. 1969. A theory of programs. ( 1969 ).Google Scholar
- Harley D Eades III and Aaron Stump. 2010. Hereditary Substitution for Stratified System F. International Workshop on Proof-Search in Type Theories 10 ( 2010 ).Google Scholar
- Jonathan Frankle, Peter-Michael Osera, David Walker, and Steve Zdancewic. 2016. Example-Directed Synthesis: A TypeTheoretic Interpretation. SIGPLAN Not. 51, 1 (Jan. 2016 ), 802-815.Google Scholar
- Neelakantan R. Krishnaswami. 2009. Focusing on Pattern Matching. In Proceedings of the 36th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL '09). Association for Computing Machinery, New York, NY, USA, 366-378.Google Scholar
Digital Library
- Søren B Lassen. 1999. Bisimulation in Untyped Lambda Calculus: Böhm Trees and Bisimulation up to Context. Electronic Notes in Theoretical Computer Science 20 ( 1999 ), 346-374.Google Scholar
- Søren B. Lassen. 2005. Eager Normal Form Bisimulation. In 20th Annual IEEE Symposium on Logic in Computer Science (LICS' 05). 345-354.Google Scholar
Digital Library
- Daniel Leivant. 1991. Finitely Stratified Polymorphism. Inf. Comput. 93, 1 ( July 1991 ), 93-113.Google Scholar
- Paul Blain Levy. 1999. Call-by-Push-Value : A Subsuming Paradigm. In Typed Lambda Calculi and Applications, 4th International Conference, TLCA'99, L 'Aquila, Italy, April 7-9, 1999, Proceedings (Lecture Notes in Computer Science), Jean-Yves Girard (Ed.), Vol. 1581. Springer, 228-242.Google Scholar
- Ian Mason and Carolyn Talcott. 1991. Equivalence in functional languages with efects. Journal of functional programming 1, 3 ( 1991 ), 287-327.Google Scholar
Cross Ref
- Jacob Matthews and Robert Bruce Findler. 2007. Operational Semantics for Multi-language Programs. SIGPLAN Not. 42, 1 ( 2007 ), 3-10.Google Scholar
- Robin Milner. 1977. Fully abstract models of typed-calculi. Theoretical Computer Science 4, 1 ( 1977 ), 1-22.Google Scholar
- J. H. Morris. 1968. Lambda Calculus Models of Programming Languages. Ph.D. Dissertation. Massachusets Institute of Technology.Google Scholar
- Max S. New, William J. Bowman, and Amal Ahmed. 2016. Fully Abstract Compilation via Universal Embedding. SIGPLAN Not. 51, 9 (Sept. 2016 ), 103-116.Google Scholar
Digital Library
- Peter-Michael Osera and Steve Zdancewic. 2015. Type-and-Example-Directed Program Synthesis. SIGPLAN Not. 50, 6 ( June 2015 ), 619-630.Google Scholar
- Marco Patrignani, Amal Ahmed, and Dave Clarke. 2019. Formal Approaches to Secure Compilation: A Survey of Fully Abstract Compilation and Related Work. ACM Comput. Surv. 51, 6, Article 125 ( 2019 ), 36 pages.Google Scholar
- Frank Pfenning. 1995. Structural Cut Elimination. In Proceedings of the 10th Annual IEEE Symposium on Logic in Computer Science (LICS '95). IEEE Computer Society, USA, 156.Google Scholar
Digital Library
- Andrew Pitts. 2004. Typed Operational Reasoning. In Advanced Topics in Types and Programming Languages, Benjamin C. Pierce (Ed.). The MIT Press, Chapter 7.Google Scholar
- Gordon D Plotkin. 1980. Lambda-definability in the full type hierarchy. To HB Curry: essays on combinatory logic, lambda calculus and formalism ( 1980 ), 363-373.Google Scholar
- Nadia Polikarpova and Ilya Sergey. 2019. Structuring the Synthesis of Heap-Manipulating Programs. Proc. ACM Program. Lang. 3, POPL, Article 72 ( Jan. 2019 ), 30 pages.Google Scholar
Digital Library
- Nick Rioux and Steve Zdancewic. 2020. Computation Focusing (Technical Report). Technical Report MS-CIS-20-04. Department of Computer and Information Science, University of Pennsylvania.Google Scholar
- Davide Sangiorgi, Naoki Kobayashi, and Eijiro Sumii. 2007. Environmental bisimulations for higher-order languages. In Logic in Computer Science, 2007. LICS 2007. 22nd Annual IEEE Symposium on. IEEE, 293-302.Google Scholar
Digital Library
- José Espírito Santo. 2016. The Polarized-calculus. Electr. Notes Theor. Comput. Sci. 332 ( 2016 ), 149-168.Google Scholar
- Gabriel Scherer. 2017. Deciding Equivalence with Sums and the Empty Type. SIGPLAN Not. 52, 1 ( 2017 ), 374-386.Google Scholar
- Gabriel Scherer and Didier Rémy. 2015. Which Simple Types Have a Unique Inhabitant?. In Proceedings of the 20th ACM SIGPLAN International Conference on Functional Programming (ICFP 2015 ). Association for Computing Machinery, New York, NY, USA, 243-255.Google Scholar
Digital Library
- Robert J Simmons. 2014. Structural focalization. ACM Transactions on Computational Logic (TOCL) 15, 3 ( 2014 ), 21.Google Scholar
Digital Library
- Richard Statman. 1985. Logical relations and the typed-calculus. Information and Control 65, 2-3 ( 1985 ), 85-97.Google Scholar
Cross Ref
- Eijiro Sumii and Benjamin C. Pierce. 2005. A Bisimulation for Type Abstraction and Recursion. SIGPLAN Not. 40, 1 ( 2005 ), 63-74.Google Scholar
- William W. Tait. 1967. Intensional interpretations of functionals of finite type I. Journal of Symbolic Logic 32, 2 ( 1967 ), 198-212.Google Scholar
Cross Ref
- Philip Wadler. 1989. Theorems for Free!. In Proceedings of the 4th International Symposium on Functional Programming and Computer Architecture.Google Scholar
Digital Library
- Noam Zeilberger. 2008a. Focusing and Higher-order Abstract Syntax. SIGPLAN Not. 43, 1 ( 2008 ), 359-369.Google Scholar
- Noam Zeilberger. 2008b. On the unity of duality. Annals of Pure and Applied Logic 153, 1 ( 2008 ), 66-96.Google Scholar
Cross Ref
- Jianzhou Zhao, Qi Zhang, and Steve Zdancewic. 2010. Relational Parametricity for Polymorphic Linear Lambda Calculus. In Proceedings of the Eighth ASIAN Symposium on Programming Languages and Systems (APLAS).Google Scholar
Cross Ref
Index Terms
Computation focusing
Recommendations
Axiom Directed Focusing
Types for Proofs and ProgramsSuperdeduction and deduction modulo are two methods designed to ease the use of first-order theories in predicate logic. Superdeduction modulo combines both in a single framework. Although soundness is ensured, using superdeduction modulo to extend ...
Focusing and higher-order abstract syntax
POPL '08: Proceedings of the 35th annual ACM SIGPLAN-SIGACT symposium on Principles of programming languagesFocusing is a proof-search strategy, originating in linear logic, that elegantly eliminates inessential nondeterminism, with one byproduct being a correspondence between focusing proofs and programs with explicit evaluation order. Higher-order abstract ...
Computation in focused intuitionistic logic
PPDP '15: Proceedings of the 17th International Symposium on Principles and Practice of Declarative ProgrammingWe investigate the control of evaluation strategies in a variant of the Λ-calculus derived through the Curry-Howard correspondence from LJF, a sequent calculus for intuitionistic logic implementing the focusing technique. The proof theory of focused ...






Comments