skip to main content
short-paper

Towards the formalization of SPARK 2014 semantics with explicit run-time checks using coq

Published:10 November 2013Publication History
Skip Abstract Section

Abstract

We present the first steps of a broad effort to develop a formal representation of SPARK 2014 suitable for supporting machine-verified static analyses and translations. In our initial work, we have developed technology for translating the GNAT compiler's abstract syntax trees into the Coq proof assistant, and we have formalized in Coq the dynamic semantics for a toy subset of the SPARK 2014 language. SPARK 2014 programs must ensure the absence of certain run-time errors (for example, those arising while performing division by zero, accessing non existing array cells, overflow on integer computation). The main novelty in our semantics is the encoding of (a small part of) the run-time checks performed by the compiler to ensure that any well-formed terminating SPARK programs do not lead to erroneous execution. This and other results are mechanically proved using the Coq proof assistant. The modeling of on-the-fly run-time checks within the semantics lays the foundation for future work on mechanical reasoning about SPARK 2014 program correctness (in the particular area of robustness) and for studying the correctness of compiler optimizations concerning run-time checks, among others.

References

  1. Ada reference manual. http://www.ada-auth.org/standards/ada12.html.Google ScholarGoogle Scholar
  2. Adacore Gnatprove tool. http://www.open-do.org/projects/hi-lite/gnatprove/.Google ScholarGoogle Scholar
  3. Adacore Hi-Lite project. http://www.open-do.org/projects/hi-lite/.Google ScholarGoogle Scholar
  4. Jago translation tool. https://github.com/sireum/bakar/tree/master/sireum-bakarjago.Google ScholarGoogle Scholar
  5. Sireum software analysis platform. http://www.sireum.org.Google ScholarGoogle Scholar
  6. Source code for SPARK 2014 language subset formalization. https://github.com/sireum/bakar/tree/master/sireum-bakarformalization.Google ScholarGoogle Scholar
  7. X. Leroy. Formal verification of a realistic compiler. Communications of the ACM, 52(7):107--115, 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. W. Marsh. Formal semantics of SPARK - static semantics, Oct 1994.Google ScholarGoogle Scholar
  9. I. O'Neill. Formal semantics of SPARK - dynamic semantics, Oct 1994.Google ScholarGoogle Scholar
  10. RTCA DO-178. Software considerations in airborne systems and equipment, 2011.Google ScholarGoogle Scholar
  11. RTCA DO-333. Formal methods supplement to do-178c and do-278a, 2011.Google ScholarGoogle Scholar

Index Terms

  1. Towards the formalization of SPARK 2014 semantics with explicit run-time checks using coq

              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

              • Published in

                cover image ACM SIGAda Ada Letters
                ACM SIGAda Ada Letters  Volume 33, Issue 3
                HILT '13
                December 2013
                80 pages
                ISSN:1094-3641
                DOI:10.1145/2658982
                Issue’s Table of Contents
                • cover image ACM Conferences
                  HILT '13: Proceedings of the 2013 ACM SIGAda annual conference on High integrity language technology
                  November 2013
                  100 pages
                  ISBN:9781450324670
                  DOI:10.1145/2527269

                Copyright © 2013 ACM

                Publisher

                Association for Computing Machinery

                New York, NY, United States

                Publication History

                • Published: 10 November 2013

                Check for updates

                Qualifiers

                • short-paper

              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!