Skip to main content

Theory Refinement for Program Verification

  • Conference paper
  • First Online:

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

Abstract

Recent progress in automated formal verification is to a large degree due to the development of constraint languages that are sufficiently light-weight for reasoning but still expressive enough to prove properties of programs. Satisfiability modulo theories (SMT) solvers implement efficient decision procedures, but offer little direct support for adapting the constraint language to the task at hand. Theory refinement is a new approach that modularly adjusts the modeling precision based on the properties being verified through the use of combination of theories. We implement the approach using an augmented version of the theory of bit-vectors and uninterpreted functions capable of directly injecting non-clausal refinements to the inherent Boolean structure of SMT. In our comparison to a state-of-the-art model checker, our prototype implementation is in general competitive, being several orders of magnitudes faster on some instances that are challenging for flattening, while computing models that are significantly more succinct.

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

Buying options

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 EPUB and 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

Learn about institutional subscriptions

Notes

  1. 1.

    We do support these in our implementation, but their results are treated nondeterministically, that is, as unbound variables from \( Sz \).

  2. 2.

    The shift operations \(\mathtt {\,\ll \,}, \mathtt {\,\gg _a\,}, \mathtt {\,\gg _l\,}\) assume a bit-width that is a power of two.

  3. 3.

    OpenSMT2: https://scm.ti-edu.ch/repogit/opensmt2.git, git ID: 99c960e4c; HiFrog (including cbmc that shares the CProver framework [2] with HiFrog): https://scm.ti-edu.ch/repogit/hifrog, git ID b35956f2c.

References

  1. http://verify.inf.usi.ch/hifrog/theoref

  2. http://www.cprover.org/

  3. Alt, L., Asadi, S., Chockler, H., Even Mendoza, K., Fedyukovich, G., Hyvärinen, A.E.J., Sharygina, N.: HiFrog: SMT-based function summarization for software verification. In: Legay, A., Margaria, T. (eds.) TACAS 2017. LNCS, vol. 10206, pp. 207–213. Springer, Heidelberg (2017). doi:10.1007/978-3-662-54580-5_12

    Chapter  Google Scholar 

  4. Alt, L., Fedyukovich, G., Hyvärinen, A.E.J., Sharygina, N.: A proof-sensitive approach for small propositional interpolants. In: Gurfinkel, A., Seshia, S.A. (eds.) VSTTE 2015. LNCS, vol. 9593, pp. 1–18. Springer, Cham (2016). doi:10.1007/978-3-319-29613-5_1

    Google Scholar 

  5. Biere, A., Cimatti, A., Clarke, E., Zhu, Y.: Symbolic model checking without BDDs. In: Cleaveland, W.R. (ed.) TACAS 1999. LNCS, vol. 1579, pp. 193–207. Springer, Heidelberg (1999). doi:10.1007/3-540-49059-0_14

    Chapter  Google Scholar 

  6. Bradley, A.R.: SAT-based model checking without unrolling. In: Jhala, R., Schmidt, D. (eds.) VMCAI 2011. LNCS, vol. 6538, pp. 70–87. Springer, Heidelberg (2011). doi:10.1007/978-3-642-18275-4_7

    Chapter  Google Scholar 

  7. Brady, B.A., Bryant, R.E., Seshia, S.A.: Learning conditional abstractions. In: Proceedings of FMCAD 2011, pp. 116–124. FMCAD Inc. (2011)

    Google Scholar 

  8. Brummayer, R., Biere, A.: Lemmas on demand for the extensional theory of arrays. J. Satisfiability Boolean Model. Comput. 6, 165–201 (2009)

    MathSciNet  MATH  Google Scholar 

  9. Bruttomesso, R., et al.: A lazy and layered SMT(\(\cal{BV}\)) solver for hard industrial verification problems. In: Damm, W., Hermanns, H. (eds.) CAV 2007. LNCS, vol. 4590, pp. 547–560. Springer, Heidelberg (2007). doi:10.1007/978-3-540-73368-3_54

    Chapter  Google Scholar 

  10. Cimatti, A., Griggio, A., Irfan, A., Roveri, M., Sebastiani, R.: Invariant checking of NRA transition systems via incremental reduction to LRA with EUF. In: Legay, A., Margaria, T. (eds.) TACAS 2017. LNCS, vol. 10205, pp. 58–75. Springer, Heidelberg (2017). doi:10.1007/978-3-662-54577-5_4

    Chapter  Google Scholar 

  11. Clarke, E.M., Grumberg, O., Jha, S., Lu, Y., Veith, H.: Counterexample-guided abstraction refinement. In: Emerson, E.A., Sistla, A.P. (eds.) CAV 2000. LNCS, vol. 1855, pp. 154–169. Springer, Heidelberg (2000). doi:10.1007/10722167_15

    Chapter  Google Scholar 

  12. Clarke, E.M., Grumberg, O., Jha, S., Lu, Y., Veith, H.: Counterexample-guided abstraction refinement for symbolic model checking. J. ACM 50(5), 752–794 (2003)

    Article  MathSciNet  MATH  Google Scholar 

  13. Cytron, R., Ferrante, J., Rosen, B., Wegman, M., Zadeck, F.: An efficient method of computing static single assignment form. In: Proceedings of POPL 1989, pp. 25–35. ACM (1989)

    Google Scholar 

  14. Detlefs, D., Nelson, G., Saxe, J.B.: Simplify: a theorem prover for program checking. J. ACM 52(3), 365–473 (2005)

    Article  MathSciNet  MATH  Google Scholar 

  15. Fedyukovich, G., Sery, O., Sharygina, N.: eVolCheck: incremental upgrade checker for C. In: Piterman, N., Smolka, S.A. (eds.) TACAS 2013. LNCS, vol. 7795, pp. 292–307. Springer, Heidelberg (2013). doi:10.1007/978-3-642-36742-7_21

    Chapter  Google Scholar 

  16. Gurfinkel, A., Belov, A., Marques-Silva, J.: Synthesizing safe bit-precise invariants. In: Ábrahám, E., Havelund, K. (eds.) TACAS 2014. LNCS, vol. 8413, pp. 93–108. Springer, Heidelberg (2014). doi:10.1007/978-3-642-54862-8_7

    Chapter  Google Scholar 

  17. Hadarean, L., Bansal, K., Jovanović, D., Barrett, C., Tinelli, C.: A tale of two solvers: eager and lazy approaches to bit-vectors. In: Biere, A., Bloem, R. (eds.) CAV 2014. LNCS, vol. 8559, pp. 680–695. Springer, Cham (2014). doi:10.1007/978-3-319-08867-9_45

    Google Scholar 

  18. Ho, Y.S., Chauhan, P., Roy, P., Mishchenko, A., Brayton, R.: Efficient uninterpreted function abstraction and refinement for word-level model checking. In: Proceedings of FMCAD 2016, pp. 65–72. ACM (2016)

    Google Scholar 

  19. Hyvärinen, A.E.J., Marescotti, M., Alt, L., Sharygina, N.: OpenSMT2: an SMT solver for multi-core and cloud computing. In: Creignou, N., Le Berre, D. (eds.) SAT 2016. LNCS, vol. 9710, pp. 547–553. Springer, Cham (2016). doi:10.1007/978-3-319-40970-2_35

    Google Scholar 

  20. Katz, G., Barrett, C., Harel, D.: Theory-aided model checking of concurrent transition systems. In: Proceedings of FMCAD 2015, pp. 81–88. IEEE (2015)

    Google Scholar 

  21. Kroening, D., Strichman, O.: Decision Procedures - An Algorithmic Point of View. Texts in Theoretical Computer Science. An EATCS Series, 2nd edn. Springer, Heidelberg (2016)

    Book  MATH  Google Scholar 

  22. Kutsuna, T., Ishii, Y., Yamamoto, A.: Abstraction and refinement of mathematical functions toward SMT-based test-case generation. Int. J. Softw. Tools Technol. Transf. 18(1), 109–120 (2016)

    Article  Google Scholar 

  23. McMillan, K.L.: An interpolating theorem prover. Theor. Comput. Sci. 345(1), 101–121 (2005)

    Article  MathSciNet  MATH  Google Scholar 

Download references

Acknowledgements

This work was supported by the SNF grants 163001 and 166288 and the SNF fellowship P2T1P2_161971.

Author information

Authors and Affiliations

Authors

Corresponding authors

Correspondence to Antti E. J. Hyvärinen , Sepideh Asadi , Karine Even-Mendoza , Grigory Fedyukovich , Hana Chockler or Natasha Sharygina .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2017 Springer International Publishing AG

About this paper

Cite this paper

Hyvärinen, A.E.J., Asadi, S., Even-Mendoza, K., Fedyukovich, G., Chockler, H., Sharygina, N. (2017). Theory Refinement for Program Verification. In: Gaspers, S., Walsh, T. (eds) Theory and Applications of Satisfiability Testing – SAT 2017. SAT 2017. Lecture Notes in Computer Science(), vol 10491. Springer, Cham. https://doi.org/10.1007/978-3-319-66263-3_22

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-66263-3_22

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-66262-6

  • Online ISBN: 978-3-319-66263-3

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics