skip to main content
research-article
Open Access
Artifacts Evaluated & Functional

Higher-order constrained horn clauses for verification

Published:27 December 2017Publication History
Skip Abstract Section

Abstract

Motivated by applications in automated verification of higher-order functional programs, we develop a notion of constrained Horn clauses in higher-order logic and a decision problem concerning their satisfiability. We show that, although satisfiable systems of higher-order clauses do not generally have least models, there is a notion of canonical model obtained through a reduction to a problem concerning a kind of monotone logic program. Following work in higher-order program verification, we develop a refinement type system in order to reason about and automate the search for models. This provides a sound but incomplete method for solving the decision problem. Finally, we show that there is a sense in which we can use refinement types to express properties of terms whilst staying within the higher-order constrained Horn clause framework.

Skip Supplemental Material Section

Supplemental Material

higherorderconstrainedhorn.webm

References

  1. Tewodros A. Beyene, Corneliu Popeea, and Andrey Rybalchenko. 2013. Solving Existentially Quantified Horn Clauses. In Computer Aided Verification - 25th International Conference, CAV 2013, Saint Petersburg, Russia, July 13-19, 2013. Proceedings. 869–882. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Per Bjesse, Koen Claessen, Mary Sheeran, and Satnam Singh. 1998. Lava: Hardware Design in Haskell. In Proceedings of the third ACM SIGPLAN International Conference on Functional Programming (ICFP ’98), Baltimore, Maryland, USA, September 27-29, 1998. 174–184. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Nikolaj Bjørner, Arie Gurfinkel, Kenneth L. McMillan, and Andrey Rybalchenko. 2015. Horn Clause Solvers for Program Verification. In Fields of Logic and Computation II - Essays Dedicated to Yuri Gurevich on the Occasion of His 75th Birthday. 24–51. Google ScholarGoogle ScholarCross RefCross Ref
  4. Nikolaj Bjørner, Kenneth L. McMillan, and Andrey Rybalchenko. 2012. Program Verification as Satisfiability Modulo Theories. In 10th International Workshop on Satisfiability Modulo Theories, SMT 2012, Manchester, UK, June 30 - July 1, 2012. 3–11.Google ScholarGoogle Scholar
  5. Nikolaj Bjørner, Kenneth L. McMillan, and Andrey Rybalchenko. 2013a. Higher-order Program Verification as Satisfiability Modulo Theories with Algebraic Data-types. CoRR abs/1306.5264 (2013).Google ScholarGoogle Scholar
  6. Nikolaj Bjørner, Kenneth L. McMillan, and Andrey Rybalchenko. 2013b. On Solving Universally Quantified Horn Clauses. In Static Analysis - 20th International Symposium, SAS 2013, Seattle, WA, USA, June 20-22, 2013. Proceedings. 105–125. Google ScholarGoogle ScholarCross RefCross Ref
  7. Andreas Blass and Yuri Gurevich. 1987. Computation Theory and Logic. Springer-Verlag, London, UK, UK, Chapter Existential Fixed-point Logic, 20–36. Google ScholarGoogle ScholarCross RefCross Ref
  8. Christopher H. Broadbent, Arnaud Carayol, Matthew Hague, and Olivier Serre. 2013. C-SHORe: a collapsible approach to verifying higher-order programs. In International Conference on Functional Programming, ICFP’13. ACM, 13–24. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Christopher H. Broadbent and Naoki Kobayashi. 2013. Saturation-based model checking of higher-order recursion schemes. In Computer Science Logic, CSL’13 (LIPIcs), Vol. 23. Schloss Dagstuhl – Leibniz-Zentrum fuer Informatik, 129–148.Google ScholarGoogle Scholar
  10. Angelos Charalambidis, Zoltán Ésik, and Panos Rondogiannis. 2014. Minimum Model Semantics for Extensional Higher-order Logic Programming with Negation. TPLP 14, 4-5 (2014), 725–737.Google ScholarGoogle Scholar
  11. Angelos Charalambidis, Konstantinos Handjopoulos, Panagiotis Rondogiannis, and William W. Wadge. 2013. Extensional Higher-Order Logic Programming. ACM Trans. Comput. Log. 14, 3 (2013), 21. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Weidong Chen, Michael Kifer, and David S. Warren. 1993. HiLog: A foundation for higher-order logic programming. Journal of Logic Programming 15, 3 (1993), 187–230. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Leonardo De Moura and Nikolaj Bjørner. 2008. Z3: An Efficient SMT Solver. In Proceedings of the Theory and Practice of Software, 14th International Conference on Tools and Algorithms for the Construction and Analysis of Systems (TA-CAS’08/ETAPS’08). Springer-Verlag, Berlin, Heidelberg, 337–340.Google ScholarGoogle ScholarCross RefCross Ref
  14. Sergey Grebenshchikov, Ashutosh Gupta, Nuno P. Lopes, Corneliu Popeea, and Andrey Rybalchenko. 2012. HSF(C): A Software Verifier Based on Horn Clauses - (Competition Contribution). In Tools and Algorithms for the Construction and Analysis of Systems - 18th International Conference, TACAS 2012, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2012, Tallinn, Estonia, March 24 - April 1, 2012. Proceedings. 549–551.Google ScholarGoogle Scholar
  15. Arie Gurfinkel, Temesghen Kahsai, Anvesh Komuravelli, and Jorge A. Navas. 2015. The SeaHorn Verification Framework. In Computer Aided Verification - 27th International Conference, CAV 2015, San Francisco, CA, USA, July 18-24, 2015, Proceedings, Part I. 343–361. Google ScholarGoogle ScholarCross RefCross Ref
  16. Nevin Heintze. 1995. Control-Flow Analysis and Type Systems. In Proceedings of the Static Analysis Symposium, SAS’95 (Lecture Notes in Computer Science). Springer, 189–206. Google ScholarGoogle ScholarCross RefCross Ref
  17. Nevin Heintze, Spiro Michaylov, and Peter Stuckey. 1992. CLP(âĎIJ) and some electrical engineering problems. Journal of Automated Reasoning 9, 2 (1992), 231–260. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Krystof Hoder, Nikolaj Bjørner, and Leonardo Mendonça de Moura. 2011. µZ- An Efficient Engine for Fixed Points with Constraints. In Computer Aided Verification - 23rd International Conference, CAV 2011, Snowbird, UT, USA, July 14-20, 2011. Proceedings. 457–462.Google ScholarGoogle Scholar
  19. Joxan Jaffar and Michael J. Maher. 1994. Constraint Logic Programming: A Survey. J. Log. Program. 19/20 (1994), 503–581. Google ScholarGoogle ScholarCross RefCross Ref
  20. Ranjit Jhala, Rupak Majumdar, and Andrey Rybalchenko. 2011. HMC: Verifying Functional Programs Using Abstract Interpreters. In Computer Aided Verification - 23rd International Conference, CAV 2011, Snowbird, UT, USA, July 14-20, 2011. Proceedings. 470–485.Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Naoki Kobayashi. 2013. Model Checking Higher-Order Programs. J. ACM 60, 3 (2013), 20:1–20:62.Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Naoki Kobayashi and C.-H. Luke Ong. 2009. A Type System Equivalent to the Modal Mu-Calculus Model Checking of Higher-Order Recursion Schemes. In Logic in Computer Science, LICS 2009. IEEE Computer Society, 179–188. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Naoki Kobayashi, Ryosuke Sato, and Hiroshi Unno. 2011. Predicate abstraction and CEGAR for higher-order model checking. In Programming Languages Design and Implementation, PLDI’11. ACM, 222–233. Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. James Lipton and Susana Nieva. 2007. Higher-Order Logic Programming Languages with Constraints: A Semantics. In Typed Lambda Calculi and Applications: 8th International Conference, TLCA 2007, Paris, France,June 26-28, 2007. Proceedings, Simona Ronchi Della Rocca (Ed.). Springer Berlin Heidelberg. Google ScholarGoogle ScholarCross RefCross Ref
  25. Saunders Mac Lane. 1971. Categories for the Working Mathematician. Springer. Google ScholarGoogle ScholarCross RefCross Ref
  26. Gopalan Nadathur and Dale Miller. 1990. Higher-Order Horn Clauses. J. ACM 37, 4 (1990), 777–814. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. C.-H. Luke Ong. 2006. On Model-Checking Trees Generated by Higher-Order Recursion Schemes. In Logic In Computer Science, LICS’06. IEEE Computer Society, 81–90.Google ScholarGoogle Scholar
  28. Jens Palsberg. 1998. Equality-based flow analysis versus recursive types. ACM Trans. Program. Lang. Syst. 20, 6 (1998), 1251–1264. Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. Steven J. Ramsay, Robin P. Neatherway, and C.-H. Luke Ong. 2014. A Type-Directed Abstraction Refinement Approach to Higher-Order Model Checking. In Principles of Programming Languages, POPL’14. ACM, 61–72. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. John C. Reynolds. 1972. Definitional Interpreters for Higher-order Programming Languages. In Proceedings of the ACM Annual Conference - Volume 2 (ACM ’72). 717–740. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. Patrick Maxim Rondon, Ming Kawaguchi, and Ranjit Jhala. 2008. Liquid types. In Proceedings of the ACM SIGPLAN 2008 Conference on Programming Language Design and Implementation, Tucson, AZ, USA, June 7-13, 2008. 159–169. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. Tachio Terauchi. 2010. Dependent types from counterexamples. In Proceedings of the 37th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2010, Madrid, Spain, January 17-23, 2010. 119–130. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. Hiroshi Unno and Naoki Kobayashi. 2009. Dependent type inference with interpolants. In Proceedings of the 11th International ACM SIGPLAN Conference on Principles and Practice of Declarative Programming, September 7-9, 2009, Coimbra, Portugal. 277–288. Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. Hiroshi Unno, Tachio Terauchi, and Naoki Kobayashi. 2013. Automating Relatively Complete Verification of Higher-order Functional Programs. In Proceedings of the 40th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages (POPL ’13). ACM, New York, NY, USA, 75–86. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. Niki Vazou, Alexander Bakst, and Ranjit Jhala. 2015. Bounded refinement types. In Proceedings of the 20th ACM SIGPLAN International Conference on Functional Programming, ICFP 2015, Vancouver, BC, Canada, September 1-3, 2015. 48–61. Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. Niki Vazou, Patrick Maxim Rondon, and Ranjit Jhala. 2013. Abstract Refinement Types. In Programming Languages and Systems - 22nd European Symposium on Programming, ESOP 2013, Held as Part of the European Joint Conferences on Theory and Practice of Software, ETAPS 2013, Rome, Italy, March 16-24, 2013. Proceedings. 209–228. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. Niki Vazou, Eric L. Seidel, Ranjit Jhala, Dimitrios Vytiniotis, and Simon Peyton-Jones. 2014. Refinement Types for Haskell. In Proceedings of the 19th ACM SIGPLAN International Conference on Functional Programming (ICFP ’14). 269–282. Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. William W. Wadge. 1991. Higher-Order Horn Logic Programming. In Logic Programming, Proceedings of the 1991 International Symposium, San Diego, California, USA, Oct. 28 - Nov 1, 1991. 289–303.Google ScholarGoogle Scholar
  39. He Zhu and Suresh Jagannathan. 2013. Compositional and Lightweight Dependent Type Inference for ML. In Verification, Model Checking, and Abstract Interpretation, 14th International Conference, VMCAI 2013, Rome, Italy, January 20-22, 2013. Proceedings. 295–314. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Higher-order constrained horn clauses for verification

        Recommendations

        Comments

        Login options

        Check if you have access through your login credentials or your institution to get full access on this article.

        Sign in

        Full Access

        PDF Format

        View or Download as a PDF file.

        PDF

        eReader

        View online with eReader.

        eReader
        About Cookies On This Site

        We use cookies to ensure that we give you the best experience on our website.

        Learn more

        Got it!