Deciding Functional Lists with Sublist Sets
Motivated by the problem of deciding verification conditions for the verification of functional programs, we present new decision procedures for automated reasoning about functional lists. We first show how to decide in NP the satisfiability problem for logical constraints containing equality, constructor, selectors, as well as the transitive sublist relation. We then extend this class of constraints with operators to compute the set of all sublists, and the set of objects stored in a list. Finally, we support constraints on sizes of sets, which gives us the ability to compute list length as well as the number of distinct list elements. We show that the extended theory is reducible to the theory of sets with linear cardinality constraints, and therefore still in NP. This reduction enables us to combine our theory with other decidable theories that impose constraints on sets of objects, which further increases the potential of our decidability result in verification of functional and imperative software.
KeywordsDecision Procedure Function Symbol Canonical Model Predicate Symbol Constant Symbol
Unable to display preview. Download preview PDF.
- 9.Lahiri, S., Qadeer, S.: Back to the future: revisiting precise program verification using SMT solvers. In: POPL (2008)Google Scholar
- 10.Lev-Ami, T., Immerman, N., Reps, T., Sagiv, M., Srivastava, S., Yorsh, G.: Simulating Reachability using First-Order Logic with Applications to Verification of Linked Data Structures. In: Nieuwenhuis, R. (ed.) CADE 2005. LNCS (LNAI), vol. 3632, pp. 99–115. Springer, Heidelberg (2005)CrossRefGoogle Scholar
- 11.Makanin, G.: The problem of solvability of equations in a free semigroup. Math. USSR Sbornik, 129–198 (1977); AMS (1979)Google Scholar
- 14.Odersky, M., Spoon, L., Venners, B.: Programming in Scala: a comprehensive step-by-step guide. Artima Press (2008)Google Scholar
- 15.Oppen, D.C.: Reasoning about recursively defined data structures. In: POPL, pp. 151–157 (1978)Google Scholar
- 16.Piskac, R., Suter, P., Kuncak, V.: On decision procedures for ordered collections. Technical Report LARA-REPORT-2010-001, EPFL (2010)Google Scholar
- 17.Plandowski, W.: Satisfiability of word equations with constants is in PSPACE. J. ACM 51(3) (2004)Google Scholar
- 20.Suter, P., Dotta, M., Kuncak, V.: Decision procedures for algebraic data types with abstractions. In: POPL (2010)Google Scholar
- 22.Wies, T., Muñiz, M., Kuncak, V.: On deciding functional lists with sublist sets. Technical Report EPFL-REPORT-148361, EPFL (2010), http://cs.nyu.edu/~wies/publ/on_deciding_functional_lists_with_sublist_sets.pdf
- 26.Zee, K., Kuncak, V., Rinard, M.: Full functional verification of linked data structures. In: PLDI (2008)Google Scholar